I'm writing a program for school and I really have no idea where to start. I'm really new at C/C++ programing so bare with me please :) .
I must make a program which turns "Letter" grades (eg.: A,B,C,D,E,F) into "Number?" grades (eg.:6,5,4,3,2,1) , where A=6,B=5,C=4,D=3,E=2,F=1.
Also if the grade is with a "-" (eg.: A- ; D-) the grade is substracted by 0,3 (A- = 5,7 ; B- = 4,7...)
And if it is with a "+" (eg.: A+ ; E+) the grade is summed by 0,3 (B+ = 5,3 ; C+ = 4,3...).
The even more tricky part , I think , is that A+ = 6 and F is always 1 (no matter "+" or "-".
I hope I described the program I'm trying to create well , because I translated it from my mother tongue. I really hope I won't confuse anyone with it :).
Thanks in advance !
I would start by writing down step by step what you wish the program to accomplish. The next thing it is important to know where you are getting the grades from a .txt file or is it a grade calculator (the user enters the grade and it prints to screen the number)? The first part of the actual programming I would go ahead and declare the A, B, C, etc as variables and assign the values to it then. You can do that by either a constant or an actual variable in the main program. The constant would be more appropriate if you are not modifying the variable. This will make writing the program easier since you will only need to compare the user input or the file value to a variable and you can do and else if statement to reflect that. That is how I would start an approach. It will make your life easier.
I have started making the program the same way as you said (A=6 ; B=5 , etc.) , but I don't really know how to make the +/- thing. I don't know how to write the program in order for it to show , for expample :
when It asks me to write a "Letter" grade : B+
to show : 5,3
Thank You murphyslaws for your comment ! I really appreciate it !
And sorry for maybe asking dumb questions ,but as I said I'm really new to this , if this even excuses me a little bit :( .