10-29-2010, 05:42 AM
Problem Statement:
You will be writing a simple result calculator. In your program first you will display your VU ID. Then you will ask user to enter Total marks, then you will take input for Obtained marks. After that you will calculate the percentage of marks and display Student Grade and Percentage. You will also perform exception handling in your code.
Details
First you will display your VU ID and Name
![[Image: cs614.JPG]](http://2.bp.blogspot.com/__M5L-C3oo0s/TMmZcs9QvWI/AAAAAAAAAG0/NkrTr22v-8g/s1600/cs614.JPG)
Then your program will ask user to enter total marks.
![[Image: cs614-2.JPG]](http://1.bp.blogspot.com/__M5L-C3oo0s/TMmZH7DeRbI/AAAAAAAAAGs/H1qD-ltNIUk/s1600/cs614-2.JPG)
Then your program will ask user to enter the obtained marks
![[Image: cs614-3.JPG]](http://3.bp.blogspot.com/__M5L-C3oo0s/TMmZFxO8TZI/AAAAAAAAAGk/csAxS1FiPhg/s1600/cs614-3.JPG)
Then your program should display Percentage of marks on console and Grade obtained by student in Message Dialog Box
![[Image: cs614-4.JPG]](http://3.bp.blogspot.com/__M5L-C3oo0s/TMmZF1twpDI/AAAAAAAAAGc/JiRE4qiP4Gc/s1600/cs614-4.JPG)
Here is the criteria to calculate grade
[FONT="]Obtained Marks >= 85% = A Grade[/FONT]
[FONT="]Obtained Marks <>= 75% = B Grade[/FONT]
[FONT="]Obtained Marks <>= 60% = C Grade[/FONT]
[FONT="]If obtained marks are less the 60% = F Grade[/FONT]
If user has input value other than number then your code should handle the exception. E.g. if user inputs abc
![[Image: cs614-5.JPG]](http://3.bp.blogspot.com/__M5L-C3oo0s/TMmZFuzhLWI/AAAAAAAAAGU/bHYhfrI08CA/s1600/cs614-5.JPG)
![[Image: cs614-6.JPG]](http://4.bp.blogspot.com/__M5L-C3oo0s/TMmZFffLSVI/AAAAAAAAAGM/DIchZ1isE2o/s1600/cs614-6.JPG)
Hints:
1) Keep all variables float so you could easily perform division.
I will upload solution soon. If someone want to discuss then leave a message.
You will be writing a simple result calculator. In your program first you will display your VU ID. Then you will ask user to enter Total marks, then you will take input for Obtained marks. After that you will calculate the percentage of marks and display Student Grade and Percentage. You will also perform exception handling in your code.
Details
First you will display your VU ID and Name
Then your program will ask user to enter total marks.
Then your program will ask user to enter the obtained marks
Then your program should display Percentage of marks on console and Grade obtained by student in Message Dialog Box
Here is the criteria to calculate grade
[FONT="]Obtained Marks >= 85% = A Grade[/FONT]
[FONT="]Obtained Marks <>= 75% = B Grade[/FONT]
[FONT="]Obtained Marks <>= 60% = C Grade[/FONT]
[FONT="]If obtained marks are less the 60% = F Grade[/FONT]
If user has input value other than number then your code should handle the exception. E.g. if user inputs abc
Hints:
1) Keep all variables float so you could easily perform division.
I will upload solution soon. If someone want to discuss then leave a message.
