#474
VerifLant
Se dă lista muchiilor unui graf neorientat cu n
vârfuri și o succesiune de k
vârfuri. Să se verifice dacă vârfurile din succesiune formează un lanț.
Problema | VerifLant | Operații I/O |
veriflant.in /veriflant.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #19948025 | Utilizator | |
Fișier | veriflant.cpp | Dimensiune | 669 B |
Data încărcării | 13 Ianuarie 2020, 11:10 | Scor / rezultat | Eroare de compilare |
veriflant.cpp:1:9: error: #include expects "FILENAME" or <FILENAME> #include <iostream> ^ veriflant.cpp:2:9: error: #include expects "FILENAME" or <FILENAME> #include <fstream> ^ veriflant.cpp:3:9: error: #include expects "FILENAME" or <FILENAME> #include <cmath> ^ veriflant.cpp:4:1: error: stray '\302' in program using namespace std; ^ veriflant.cpp:4:1: error: stray '\240' in program veriflant.cpp:4:1: error: stray '\302' in program veriflant.cpp:4:1: error: stray '\240' in program veriflant.cpp:6:1: error: stray '\302' in program int nr_prim(int n){ ^ veriflant.cpp:6:1: error: stray '\240' in program veriflant.cpp:6:1: error: stray '\302' in program veriflant.cpp:6:1: error: stray '\240' in program veriflant.cpp:8:1: error: stray '\302' in program int i,este_prim=1; ^ veriflant.cpp:8:1: error: stray '\240' in program veriflant.cpp:10:1: error: stray '\302' in program return 0; ^ veriflant.cpp:10:1: error: stray '\240' in program veriflant.cpp:19:1: error: stray '\302' in program return este_prim; ^ veriflant.cpp:19:1: error: stray '\240' in program veriflant.cpp:22:1: error: stray '\302' in program int main(){ ^ veriflant.cpp:22:1: error: stray '\240' in program veriflant.cpp:23:1: error: stray '\302' in program ifstream sgi("subgraf.in"); ^ veriflant.cpp:23:1: error: stray '\240' in program veriflant.cpp:24:1: error: stray '\302' in program ofstream sgo("subgraf.out"); ^ veriflant.cpp:24:1: error: stray '\240' in program veriflant.cpp:25:1: error: stray '\302' in program int n,i,j,a[101][101],nr_neprime[100],nr=0,s=0,M; ^ veriflant.cpp:25:1: error: stray '\240' in program veriflant.cpp:47:1: error: stray '\302' in program return 0; ^ veriflant.cpp:47:1: error: stray '\240' in program veriflant.cpp: In function 'int nr_prim(int)': veriflant.cpp:13:18: error: 'sqrt' was not declared in this scope for(i=2;i<=sqrt(n);i++){ ^ veriflant.cpp: In function 'int main()': veriflant.cpp:23:1: error: 'ifstream' was not declared in this scope ifstream sgi("subgraf.in"); ^ veriflant.cpp:23:11: error: expected ';' before 'sgi' ifstream sgi("subgraf.in"); ^ veriflant.cpp:24:1: error: 'ofstream' was not declared in this scope ofstream sgo("subgraf.out"); ^ veriflant.cpp:24:11: error: expected ';' before 'sgo' ofstream sgo("subgraf.out"); ^ veriflant.cpp:26:1: error: 'sgi' was not declared in this scope sgi>>n; ^ veriflant.cpp:37:1: error: 'cout' was not declared in this scope cout<<nr_neprime[i]<<" "; ^ veriflant.cpp:45:1: error: 'sgo' was not declared in this scope sgo<<M; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema VerifLant face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:
Suma punctajelor acordate pe testele utilizate pentru verificare este 100. Astfel, soluția ta poate obține cel mult 100 de puncte, caz în care se poate considera corectă.