What is wrong with the following code?
int total, number;
int counter = 0;
while (counter < 10)
{
cin >> number;
total = total + number;
counter = counter + 1;
}
total must be initialized to 0.
Computer Science & Information Technology