Hi l just started learning C++ and I have a program for a prompt :
It goes along the lines of asking the user for inputs of their assignments one at a time and once they have no more inputs, the program must display
"Stop"
It must ask the user if they have more scores to enter once each score (boolean type)
It must also obtain the average and place it on a scale of 100 and output the score associated, scale being:
A = 100-93
,A- = 92-90
,B+ = 89-87
etc
Below is what I have so far (please let me know if I can format it better for compiler, I prefer to type in notepad)
#include <iostream>
using namespace std;
int main() {
cout << "Welcome to the Homework Point Sum Progam!"
endl;
cout << "How many assignments did you complete?:";
endl;
int assignments;
int scores;
int total = 0;
int average = scores / assignents;
cin >> assignments;
// this next part I'm trying to find out how to set up the input for the assignments and have them line up as "assignment one, assignment two, etc."
if (assignment > 0) {
for (int i = 1; i < assignment; i++) {
else
// I would like to know if this is a valid input and formatting of "else" as well as if my placement of it is valid
cout << "Enter Assignment Score" << i << endl;
cin >> scores
total += scores
}
}
if (average < 33)
total += scores
cout << "Fail" << endl:
return 0;
}