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
|
prog.cpp:7:25: error: variable or field 'populate_div_sales' declared void
void populate_div_sales(DIV[], int);
^
prog.cpp:7:25: error: 'DIV' was not declared in this scope
prog.cpp:7:29: error: expected primary-expression before ']' token
void populate_div_sales(DIV[], int);
^
prog.cpp:7:32: error: expected primary-expression before 'int'
void populate_div_sales(DIV[], int);
^
prog.cpp:8:18: error: 'DIV' was not declared in this scope
int findHighest (DIV[], int);
^
prog.cpp:8:22: error: expected primary-expression before ']' token
int findHighest (DIV[], int);
^
prog.cpp:8:25: error: expected primary-expression before 'int'
int findHighest (DIV[], int);
^
prog.cpp:8:28: error: expression list treated as compound expression in initializer [-fpermissive]
int findHighest (DIV[], int);
^
prog.cpp:9:19: error: variable or field 'print_result' declared void
void print_result(DIV[], int);
^
prog.cpp:9:19: error: 'DIV' was not declared in this scope
prog.cpp:9:23: error: expected primary-expression before ']' token
void print_result(DIV[], int);
^
prog.cpp:9:26: error: expected primary-expression before 'int'
void print_result(DIV[], int);
^
prog.cpp: In function 'int main()':
prog.cpp:21:14: error: expected initializer before '.' token
DIV div_info.name = {"Northeast", "Northwest", "Southeast", "Southwest"};
^
prog.cpp:23:32: error: 'populate_div_sales' was not declared in this scope
populate_div_sales(div_info, 4);
^
prog.cpp:25:2: error: 'winner' was not declared in this scope
winner = int findHighest(div_info, 4);
^
prog.cpp:25:11: error: expected primary-expression before 'int'
winner = int findHighest(div_info, 4);
^
prog.cpp:27:26: error: 'print_result' was not declared in this scope
print_result(div_info, 4);
^
prog.cpp: At global scope:
prog.cpp:33:38: error: expected ',' or '...' before numeric constant
void print_result(DIV div_info, int 4)
^
prog.cpp: In function 'void print_result(DIV, int)':
prog.cpp:37:12: error: 'array' was not declared in this scope
cout << array[i] << endl;
^
prog.cpp: At global scope:
prog.cpp:41:44: error: expected ',' or '...' before numeric constant
void populate_div_sales(DIV div_info, int 4)
^
prog.cpp: In function 'void populate_div_sales(DIV, int)':
prog.cpp:45:26: error: invalid types 'float[int]' for array subscript
cin >> div_info.sale[i];
^
prog.cpp:46:26: error: invalid types 'float[int]' for array subscript
while (div_info.sale[i]<=0){
^
prog.cpp:50:2: error: 'Int' was not declared in this scope
Int findHighest(DIV div_info.sale, int 4)
^
prog.cpp:62:1: error: expected '}' at end of input
}
^
|