Borderou de evaluare (job #2760584)
Utilizator | Data | 28 iunie 2021 00:13:15 | |
---|---|---|---|
Problema | Paranteze | Status | done |
Runda | Arhiva de probleme | Compilator | cpp-64 | Vezi sursa |
Scor | 0 |
Raport evaluator
Eroare de compilare:
main.cpp:10:38: error: invalid declarator before 'Pozitii'
stack <char> Paranteze, stack <int> Pozitii;
^~~~~~~
main.cpp: In function 'void Rezolvare(char, int)':
main.cpp:16:63: error: 'Pozitii' was not declared in this scope
if (c == '(' || c == '[' || c == '{') Paranteze.push(c), Pozitii.push(i);
^~~~~~~
main.cpp:19:36: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if (Paranteze.top() == '(' && c == ')' || Paranteze.top() == '[' && c == ']' || Paranteze.top() == '{' && c == '}')
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~
main.cpp:19:112: warning: suggest parentheses around '&&' within '||' [-Wparentheses]
if (Paranteze.top() == '(' && c == ')' || Paranteze.top() == '[' && c == ']' || Paranteze.top() == '{' && c == '}')
~~~~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~
main.cpp:22:30: error: 'Pozitii' was not declared in this scope
Paranteze.pop(), Pozitii.pop();
^~~~~~~
main.cpp:32:32: error: 'Pozitii' was not declared in this scope
Paranteze.push(c), Pozitii.push(i);
^~~~~~~
main.cpp: In function 'int main()':
main.cpp:45:1: error: expected '}' at end of input
}
^
Non zero exit status: 1
Ceva nu functioneaza?
- Citeste despre borderoul de evaluare.
- Daca tot nu e bine, contacteaza-ne pe forum !