# http://imgur.com/A3X8CWn Please help me correct my program or write one that i can edit SOURCE CODE:

SOURCE CODE:

/*
Donald Krambeck
Homework 4
My program inputs the values of the grade[] array,
and calculates the total and avarage. It then displays
the value of the total, average, and the grades.
*/

#include <iostream>
using namespace std;

int main()
{
double grade[100]; //double data type array
double total = 0, avg = 0; // double data type variables
int i, count = 0; //int data type array

cout << ” Please enter the values of grades ” << endl; //display output

for (i = 0; grade[i]; != ‘’; i++) //loop to input values
{
}

if (grade[i] > 0) //condition to check negative values
{

count++; //increase the counter by one
}
else
{
break; //break from loop
}

avg = total / count; //calculates the average

cout << ” The total of all the grades is ” << total << endl;
cout << ” The average of all the grades is ” << avg << endl;
cout << “The grades below average are ” << endl;

for (i = 0; i < count; i++) //loop to find grades below average
{
{
cout << ” * ” << grade[i] << endl;
}
}

for (i = 0; i < count; i++) //find equivalent letter for the grade
{
{
cout << grade[i] << ” = F ” << endl;
}
{
cout << grade[i] << ” = D ” << endl;
}
{
cout << grade[i] << ” = C ” << endl;
}