I keep receiving these errors

I am trying to input a loop that displays income generated from ticket sales for 3 nights.. I keep receiving error messages even when I go to the line and think I fixed the problem. Any help would be great


1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
// add the following lines at the beginning of the source file
#include <iostream>

using namespace std;

// create translation from generic keywords to C++
#define Declare
#define ByRef ref
#define Call
#define Constant const
#define Declare
#define Display cout <<
#define Eof cin.eof()
#define Function
#define Input cin >>
#define InputLine(x) getline(cin, x)
#define Integer int
#define Module
#define Newline endl
#define Real double
#define String string
#define Set

int main()
{
int A, B, C ;
int TotalIncome[3]
for (int i = 0; i< 3; i++);
{

cout << "Enter number of seats sold in Section A: \n";
cin >>  A;


cout << "Enter number of seats sold in Section B: \n";
cin >> B;



cout << "Enter a number of seats sold in Section C: \n";
cin >>  C;

while (A < 0 or A > 300)
{
cout << "ERROR: Seats sold in Section A cannot be \n";
cout << "greater than 300 or negative.\n ";

cout << "Enter valid value for seats sold in section A: \n";
cout << "A value in the range of 0 to 300 inclusive. \n";
cin >> A;
}
while (B < 0 or B > 500)
{
cout << "ERROR: Seats sold in Section B cannot be \n";
cout << "greater than 500 or negative.\n ";

cout << "Enter valid value for seats sold in section C: \n";
cout << "A value in the range of 0 to 500 inclusive. \n";
cin >> B;
}
while (C < 0 or C > 200)
{
cout << "ERROR: Seats sold in Section C cannot be \n";
cout << "greater than 200 or negative.\n ";

cout << "Enter valid value for seats sold in section C: \n";
cout << "A value in the range of 0 to 200 inclusive. \n";
cin >> C;
}
TotalIncome[i] = (A * 20) + (B * 15) + (C * 10);
}
for (int i=0; i<3; i++)
{
cout << "The total income generated from ticket sales \n ";
cout << "of all sections is $ " << TotalIncome[i];
}
}

}






ERRORS:
F:\CH7Q2Theater.cpp|27|error: 'i' was not declared in this scope|
F:\CH7Q2Theater.cpp|70|error: 'TotalIncome' was not declared in this scope|
F:\CH7Q2Theater.cpp|75|error: 'TotalIncome' was not declared in this scope|
F:\CH7Q2Theater.cpp|79|error: expected declaration before '}' token|
closed account (j3Rz8vqX)
Line 27, missing a semi colon;

Line 70, was flagged error due to line 27;

Line 75, same as before.

Line 79, one too many semi colon.

Also, on line 28, delete the semi colon after for-loop.
Do I need to include a string of days so it will ask separately the input for Thursday-Saturday?



*btw that worked
Topic archived. No new replies allowed.