#418
Subgraf
Se dă lista muchiilor unui graf neorientat cu n
vârfuri, etichetate de la 1
la n
. Din acest graf se elimină toate vârfurile etichetate cu valori prime. Să se determine câte muchii va avea subgraful obținut.
Problema | Subgraf | Operații I/O |
subgraf.in /subgraf.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #52760740 | Utilizator | |
Fișier | subgraf.cpp | Dimensiune | 586 B |
Data încărcării | 08 Octombrie 2024, 19:41 | Scor / rezultat | Eroare de compilare |
subgraf.cpp:8:1: error: stray '\302' in program if(n<=1) ^ subgraf.cpp:8:1: error: stray '\240' in program subgraf.cpp:8:1: error: stray '\302' in program subgraf.cpp:8:1: error: stray '\240' in program subgraf.cpp:9:1: error: stray '\302' in program return 0; ^ subgraf.cpp:9:1: error: stray '\240' in program subgraf.cpp:9:1: error: stray '\302' in program subgraf.cpp:9:1: error: stray '\240' in program subgraf.cpp:10:1: error: stray '\302' in program if(n==2) ^ subgraf.cpp:10:1: error: stray '\240' in program subgraf.cpp:10:1: error: stray '\302' in program subgraf.cpp:10:1: error: stray '\240' in program subgraf.cpp:11:1: error: stray '\302' in program return 1; ^ subgraf.cpp:11:1: error: stray '\240' in program subgraf.cpp:11:1: error: stray '\302' in program subgraf.cpp:11:1: error: stray '\240' in program subgraf.cpp:12:1: error: stray '\302' in program if(n%2==0) ^ subgraf.cpp:12:1: error: stray '\240' in program subgraf.cpp:12:1: error: stray '\302' in program subgraf.cpp:12:1: error: stray '\240' in program subgraf.cpp:13:1: error: stray '\302' in program return 0; ^ subgraf.cpp:13:1: error: stray '\240' in program subgraf.cpp:13:1: error: stray '\302' in program subgraf.cpp:13:1: error: stray '\240' in program subgraf.cpp:14:1: error: stray '\302' in program for(int i=3;i*i<=n;i+=2) ^ subgraf.cpp:14:1: error: stray '\240' in program subgraf.cpp:14:1: error: stray '\302' in program subgraf.cpp:14:1: error: stray '\240' in program subgraf.cpp:15:1: error: stray '\302' in program if(n%i==0) ^ subgraf.cpp:15:1: error: stray '\240' in program subgraf.cpp:15:1: error: stray '\302' in program subgraf.cpp:15:1: error: stray '\240' in program subgraf.cpp:16:1: error: stray '\302' in program return 0; ^ subgraf.cpp:16:1: error: stray '\240' in program subgraf.cpp:16:1: error: stray '\302' in program subgraf.cpp:16:1: error: stray '\240' in program subgraf.cpp:17:1: error: stray '\302' in program return 1; ^ subgraf.cpp:17:1: error: stray '\240' in program subgraf.cpp:17:1: error: stray '\302' in program subgraf.cpp:17:1: error: stray '\240' in program subgraf.cpp:24:1: error: stray '\302' in program if(!prim(x)&&!prim(y)) ^ subgraf.cpp:24:1: error: stray '\240' in program subgraf.cpp:24:1: error: stray '\302' in program subgraf.cpp:24:1: error: stray '\240' in program subgraf.cpp:25:1: error: stray '\302' in program if(a[x][y]==0) ^ subgraf.cpp:25:1: error: stray '\240' in program subgraf.cpp:25:1: error: stray '\302' in program subgraf.cpp:25:1: error: stray '\240' in program subgraf.cpp:26:1: error: stray '\302' in program { ^ subgraf.cpp:26:1: error: stray '\240' in program subgraf.cpp:26:1: error: stray '\302' in program subgraf.cpp:26:1: error: stray '\240' in program subgraf.cpp:27:1: error: stray '\302' in program a[x][y]=1; ^ subgraf.cpp:27:1: error: stray '\240' in program subgraf.cpp:27:1: error: stray '\302' in program subgraf.cpp:27:1: error: stray '\240' in program subgraf.cpp:27:1: error: stray '\302' in program subgraf.cpp:27:1: error: stray '\240' in program subgraf.cpp:27:1: error: stray '\302' in program subgraf.cpp:27:1: error: stray '\240' in program subgraf.cpp:28:1: error: stray '\302' in program a[y][x]=1; ^ subgraf.cpp:28:1: error: stray '\240' in program subgraf.cpp:28:1: error: stray '\302' in program subgraf.cpp:28:1: error: stray '\240' in program subgraf.cpp:28:1: error: stray '\302' in program subgraf.cpp:28:1: error: stray '\240' in program subgraf.cpp:28:1: error: stray '\302' in program subgraf.cpp:28:1: error: stray '\240' in program subgraf.cpp:29:1: error: stray '\302' in program nr++; ^ subgraf.cpp:29:1: error: stray '\240' in program subgraf.cpp:29:1: error: stray '\302' in program subgraf.cpp:29:1: error: stray '\240' in program subgraf.cpp:29:1: error: stray '\302' in program subgraf.cpp:29:1: error: stray '\240' in program subgraf.cpp:29:1: error: stray '\302' in program subgraf.cpp:29:1: error: stray '\240' in program subgraf.cpp:30:1: error: stray '\302' in program } ^ subgraf.cpp:30:1: error: stray '\240' in program subgraf.cpp:30:1: error: stray '\302' in program subgraf.cpp:30:1: error: stray '\240' in program subgraf.cpp:32:1: error: stray '\302' in program fout<<nr; ^ subgraf.cpp:32:1: error: stray '\240' in program subgraf.cpp:32:1: error: stray '\302' in program subgraf.cpp:32:1: error: stray '\240' in program subgraf.cpp:33:1: error: stray '\302' in program return 0; ^ subgraf.cpp:33:1: error: stray '\240' in program subgraf.cpp:33:1: error: stray '\302' in program subgraf.cpp:33:1: error: stray '\240' in program
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Subgraf 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ă.