Vbn70us Supp Exam
Vbn70us Supp Exam
Vbn70us Supp Exam
DEGREE
YEAR 3
MAY/JUNE 2021
Instructions to Candidates:
Question 1
As part of the IUM rules a student should attend 80% of all classes. A student will not be
allowed to sit in exam if his/her attendance is less than 75%. Create a program in Visual
Basic, Take the following input from user:
- Number of classes held
- Number of classes attended.
And print
- percentage of class attended
- Is student is allowed to sit in exam or not.
[Total 20 Marks]
Question 2
Develop an application in Visual Basic to calculate the employees Gross Pay. The formula to
calculate the Gross Pay: GP = HW * HP
GP = Gross Pay
HW = Number of Hours Worked
HP = Hourly Pay Rate
[Total 20 Marks]
1
Question 3
A school has following rules for grading system. Write a program in Visual Basic that
determines a student’s grade. Ask the user to enter marks and the program will read the score
and determine the grade based on the following rules:
Marks Grade
80 and above A
70 – 79 B
60 – 69 C
50 – 59 D
0 – 49 F
Question 4
Professor Haimbondi wants to calculate the factorial numbers in his mathematic class. As an
IT student, you are the best candidate to help him solve his problem. With the aid of your
Visual basic expertise, write a program that will print the factorial of a number by defining a
method named 'Factorial'. You should name your program Factorial.
Factorial of any number n is represented by n! and is equal to 1*2*3*....*(n-1)*n. E.g.-
4! = 1*2*3*4 = 24
3! = 3*2*1 = 6
2! = 2*1 = 2
Also, 1! = 1, 0! = 0
[Total 20 Marks]
2
Section B (Answer all questions)
Question 1
[Total 20 Marks]
Question 2
[Total 20 Marks]