Problem | sumint |
---|---|
User | tacticalnerd |
Submission Time | 2024-04-13 11:00:58 |
Score | 0 |
Max Time | N/A |
Max Memory | N/A |
Owl Get a Life
sumint.cpp: In function ‘int main()’:
sumint.cpp:6:10: error: expected ‘;’ before ‘int’
6 | cin >> d
| ^
| ;
7 | int num[d];
| ~~~
sumint.cpp:8:17: error: expected ‘;’ before ‘<’ token
8 | for (int i=0, i<d, i++) {
| ^
| ;
sumint.cpp:8:17: error: expected primary-expression before ‘<’ token
sumint.cpp:8:24: error: expected ‘;’ before ‘)’ token
8 | for (int i=0, i<d, i++) {
| ^
| ;
sumint.cpp:9:10: error: ‘num’ was not declared in this scope; did you mean ‘sum’?
9 | sum += num[i];
| ^~~
| sum