#include <iostream>

using namespace std;

void acceptedScores(int numOfstudents);
int printedScores();

int main()
{
    int students;
    int numStudents;
    int scores;
    int numOfStudents[100] = students;
    char cont;
    cont = 'y';
    cout << "Would you like to begin (Y or y)" << endl;
    cin >> cont;
    while(cont=='Y' || cont== 'y')
    {
                    cout<<"Please enter the number of students who took the exam"<<endl;
                    cin>> students;
                    while(numStudents > students)
                    {
                       cout << " Please enter the score for each student who took the exam" << endl;
                       cin >> scores;
                       numStudents++;
                    }
    }
acceptScores (numOfStudents);
printedScores ();
system ("pause");
return 0;
}
void acceptScores(int numOfStudents)
     
     int scores
     for (scores >= 90 );
     {
        A++;
        }
        for (scores >= 80);
        {
            B++;
            }
            for (scores >= 70);
            {
               C++;
               }
               for (scores >= 60);
               {
                  D++;
                  }
                 for (scores >= 0);
                 {
                      E++;
                      }
return A, B, C, D, E;
}
int printedScores()
{
     int A = 0;
     int B = 0;
     int C = 0;
     int D = 0;
     int E = 0;
    int students
    cout << "The scores entered are:"<<scores<<endl;
    for (grade = 0; grade) 
    cout << "A(s)" << A << endl;
    cout << "B(s)" << B << endl;
    cout << "C(s)" << C << endl;
    cout << "D(s)" << D << endl;
    cout << "E(s)" << E << endl;
}
//attempting to initialize with an uninitialized value out of bounds of the array
int numOfStudents[100] = students;

//function name spelled wrong
acceptScores (numOfStudents);

//Here you try to pass an array pointer to a function prototyped to accept an int
acceptedScores (numOfStudents);

//You should dereference the pointer to an int using an array subscript
acceptedScores (numOfStudents[1]);

//The function definition:  the function name is spelled wrong/does not match it's prototype.  Additionally, you lack a starting { curley brace to start the block of code.  
void acceptScores(int numOfStudents)

//All these 'for' statements should be 'if'
//also, you can't have a ; semicolon after an if() condition
//also, you create a variable 'scores' but never assign anything to it.
for (scores >= 80);

//You cannot 'return' anything in a void function()
//Even if you could, you can only return one item 
return A, B, C, D, E;

//missing semicolon in printedscores() function
int students

//variable not declared inside of printedscores()
scores

//incorrect for loop condition
//should be something like for(int grade=0; grade<=students; grade++)
for (grade = 0; grade)
Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.