Borderou de evaluare (job #1555754)

Utilizator valentin50517Vozian Valentin valentin50517 Data 23 decembrie 2015 15:21:04
Problema Perle2 Status done
Runda Arhiva de probleme Compilator cpp | Vezi sursa
Scor 0

Raport evaluator

Eroare de compilare: user.cpp:4:7: error: expected nested-name-specifier before ‘namesapce’ using namesapce std; ^ user.cpp:4:7: error: ‘namesapce’ has not been declared user.cpp:4:17: error: expected ‘;’ before ‘std’ using namesapce std; ^ user.cpp:4:17: error: ‘std’ does not name a type user.cpp:5:1: error: ‘ifstream’ does not name a type ifstream fin("perle2.in"); ^ user.cpp:6:1: error: ‘ofstream’ does not name a type ofstream fout("perle2.out"); ^ user.cpp: In function ‘int main()’: user.cpp:10:5: error: ‘fin’ was not declared in this scope fin >> N >> K; ^ user.cpp:19:54: error: ‘max’ was not declared in this scope dp[j] = max(dp[j],pre[j]-pre[i-1]); ^ user.cpp:19:54: note: suggested alternative: In file included from /usr/include/c++/4.8/algorithm:62:0, from user.cpp:2: /usr/include/c++/4.8/bits/stl_algo.h:4259:5: note: ‘std::max’ max(initializer_list<_Tp> __l, _Compare __comp) ^ user.cpp:22:41: error: ISO C++ forbids comparison between pointer and integer [-fpermissive] for(int i = 0;i<=N;i++) if(rs < dp[i]) rs = dp[i]; ^ user.cpp:22:53: error: invalid conversion from ‘int*’ to ‘int’ [-fpermissive] for(int i = 0;i<=N;i++) if(rs < dp[i]) rs = dp[i]; ^ user.cpp:23:5: error: ‘fout’ was not declared in this scope fout << rs; ^

Ceva nu functioneaza?