Revision Programs

Set 2

Result Problems

1.

  1. Input name of a student and two marks. Marks are out of 40 for each subject. Find percentage of total and print it along with name.

2.1.

  1. Input name and two marks. Marks are out of 40 for each subject. Find percentage of total.
    If percentage is 40 or above print "Admission is granted" along with name.
    Otherwise nothing to be done.

2.2.

  1. Input two marks of a student. Marks are in 40 each. Find percentage of total.
    If percentage is 40 or above print "Admission is granted".
    Otherwise print "No Admission."

2.3.

  1. Input percentage of marks. Print result.
    percentage 80 or above : Distinction. 60 or above : First class.
    percentage 50 or above : Second class. 40 or above : Third class.
    Others : Failed

2.4.

  1. Input percentage of marks and syllabus. Print result.
    ExcellentGoodSatisfactory
    ICSE (I)Mark: >=75Mark: >=50 Below 50
    CBSE (C) Mark: >=80Mark: >=60 Below 60
    Others Wrong choice

2.5.

  1. Write a menu driven program:
    1) Input average, print "Passed" or "Failed". Pass mark is 40 or above.
    2) Input percentage, print "Admission granted" or "No admission". Admission percentage is 80 or above.

3.1.

  1. Input name and percentage of marks of n students. Print "Admission granted" or "No admission" with name. Admission mark is 80 or above. Also find total number of students who got admission.

3.2.

  1. Input name and percentage of marks of some students. Print "Admission granted" or "No admission". Admission mark is 80 or above. Also find total number of students who got admission.
    Program should continue as long as user wishes.

3.3

  1. Input name and percentage of marks of some students. Print "Admission granted" or "No admission". Admission mark is 80 or above. Also find total number of students who got admission.
    Program should continue as long as user wishes.

3.4.

  1. Input n students’ name and m subjects marks. Print average mark of each student.

4.1.

  1. Input name and percentage of marks of n students into two arrays. Print two separate lists.
    1) Those who got admission along with mark, 2) Those who do not get admission. Admission mark is 80 or above.
    Also print total number of students who got admission.

4.2.

  1. Input 30 students’ 10 subjects’ marks. Print a list of students who got mark 80 or above.
    Output format:
    90.0 : 0 0
    85.0 : 2 1
    93.5 : 3 4

5.1.

  1. Define a class to overload methods named int analyze():
    1. to count the students who got mark 80 or above of the n input marks
    2. to count the students who got mark 60 or above and less than 80 of the n input marks

6.1.

  1. Define a class Result with the following descriptions:
    Data members/Instance variables: int roll, String name, double mark, String result
    Member methods:
    1) Result() - parameterized constructor
    2) dataEntry() - to input necessary details
    3) process() - to find and store result
    mark 80 or above : Distinction. 60 or above : First class.
    mark 50 or above : Second class. 40 or above : Third class.
    Others : Failed
    4) print() - to display details along with result