#515
SortSD
Se dau n
numere naturale. Afișați aceste numere ordonate crescător după suma divizorilor. Dacă două numere au aceeași sumă a divizorilor, se va afișa mai întâi cel mai mic.
Problema | SortSD | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #21658859 | Utilizator | |
Fișier | sortsd.cpp | Dimensiune | 1.09 KB |
Data încărcării | 08 Martie 2020, 20:24 | Scor / rezultat | Eroare de compilare |
sortsd.cpp:11:1: error: stray '\302' in program cin >> n; ^ sortsd.cpp:11:1: error: stray '\240' in program sortsd.cpp:11:1: error: stray '\302' in program sortsd.cpp:11:1: error: stray '\240' in program sortsd.cpp:13:1: error: stray '\302' in program for (i=1; i<=n; ++i) ^ sortsd.cpp:13:1: error: stray '\240' in program sortsd.cpp:13:1: error: stray '\302' in program sortsd.cpp:13:1: error: stray '\240' in program sortsd.cpp:15:1: error: stray '\302' in program { ^ sortsd.cpp:15:1: error: stray '\240' in program sortsd.cpp:15:1: error: stray '\302' in program sortsd.cpp:15:1: error: stray '\240' in program sortsd.cpp:17:1: error: stray '\302' in program cin >> v[i]; ^ sortsd.cpp:17:1: error: stray '\240' in program sortsd.cpp:17:1: error: stray '\302' in program sortsd.cpp:17:1: error: stray '\240' in program sortsd.cpp:17:1: error: stray '\302' in program sortsd.cpp:17:1: error: stray '\240' in program sortsd.cpp:17:1: error: stray '\302' in program sortsd.cpp:17:1: error: stray '\240' in program sortsd.cpp:19:1: error: stray '\302' in program num=v[i]; ^ sortsd.cpp:19:1: error: stray '\240' in program sortsd.cpp:19:1: error: stray '\302' in program sortsd.cpp:19:1: error: stray '\240' in program sortsd.cpp:19:1: error: stray '\302' in program sortsd.cpp:19:1: error: stray '\240' in program sortsd.cpp:19:1: error: stray '\302' in program sortsd.cpp:19:1: error: stray '\240' in program sortsd.cpp:21:1: error: stray '\302' in program s=0; ^ sortsd.cpp:21:1: error: stray '\240' in program sortsd.cpp:21:1: error: stray '\302' in program sortsd.cpp:21:1: error: stray '\240' in program sortsd.cpp:21:1: error: stray '\302' in program sortsd.cpp:21:1: error: stray '\240' in program sortsd.cpp:21:1: error: stray '\302' in program sortsd.cpp:21:1: error: stray '\240' in program sortsd.cpp:23:1: error: stray '\302' in program for (d=1; d*d<=num; ++d) ^ sortsd.cpp:23:1: error: stray '\240' in program sortsd.cpp:23:1: error: stray '\302' in program sortsd.cpp:23:1: error: stray '\240' in program sortsd.cpp:23:1: error: stray '\302' in program sortsd.cpp:23:1: error: stray '\240' in program sortsd.cpp:23:1: error: stray '\302' in program sortsd.cpp:23:1: error: stray '\240' in program sortsd.cpp:25:1: error: stray '\302' in program { ^ sortsd.cpp:25:1: error: stray '\240' in program sortsd.cpp:25:1: error: stray '\302' in program sortsd.cpp:25:1: error: stray '\240' in program sortsd.cpp:25:1: error: stray '\302' in program sortsd.cpp:25:1: error: stray '\240' in program sortsd.cpp:25:1: error: stray '\302' in program sortsd.cpp:25:1: error: stray '\240' in program sortsd.cpp:27:1: error: stray '\302' in program if (num%d==0) ^ sortsd.cpp:27:1: error: stray '\240' in program sortsd.cpp:27:1: error: stray '\302' in program sortsd.cpp:27:1: error: stray '\240' in program sortsd.cpp:27:1: error: stray '\302' in program sortsd.cpp:27:1: error: stray '\240' in program sortsd.cpp:27:1: error: stray '\302' in program sortsd.cpp:27:1: error: stray '\240' in program sortsd.cpp:27:1: error: stray '\302' in program sortsd.cpp:27:1: error: stray '\240' in program sortsd.cpp:27:1: error: stray '\302' in program sortsd.cpp:27:1: error: stray '\240' in program sortsd.cpp:29:1: error: stray '\302' in program { ^ sortsd.cpp:29:1: error: stray '\240' in program sortsd.cpp:29:1: error: stray '\302' in program sortsd.cpp:29:1: error: stray '\240' in program sortsd.cpp:29:1: error: stray '\302' in program sortsd.cpp:29:1: error: stray '\240' in program sortsd.cpp:29:1: error: stray '\302' in program sortsd.cpp:29:1: error: stray '\240' in program sortsd.cpp:29:1: error: stray '\302' in program sortsd.cpp:29:1: error: stray '\240' in program sortsd.cpp:29:1: error: stray '\302' in program sortsd.cpp:29:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program s=s+d; ^ sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:31:1: error: stray '\302' in program sortsd.cpp:31:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program if (d*d!=num) s=s+num/d; ^ sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:33:1: error: stray '\302' in program sortsd.cpp:33:1: error: stray '\240' in program sortsd.cpp:35:1: error: stray '\302' in program } ^ sortsd.cpp:35:1: error: stray '\240' in program sortsd.cpp:35:1: error: stray '\302' in program sortsd.cpp:35:1: error: stray '\240' in program sortsd.cpp:35:1: error: stray '\302' in program sortsd.cpp:35:1: error: stray '\240' in program sortsd.cpp:35:1: error: stray '\302' in program sortsd.cpp:35:1: error: stray '\240' in program sortsd.cpp:35:1: error: stray '\302' in program sortsd.cpp:35:1: error: stray '\240' in program sortsd.cpp:35:1: error: stray '\302' in program sortsd.cpp:35:1: error: stray '\240' in program sortsd.cpp:37:1: error: stray '\302' in program } ^ sortsd.cpp:37:1: error: stray '\240' in program sortsd.cpp:37:1: error: stray '\302' in program sortsd.cpp:37:1: error: stray '\240' in program sortsd.cpp:37:1: error: stray '\302' in program sortsd.cpp:37:1: error: stray '\240' in program sortsd.cpp:37:1: error: stray '\302' in program sortsd.cpp:37:1: error: stray '\240' in program sortsd.cpp:39:1: error: stray '\302' in program sdiv[i]=s; ^ sortsd.cpp:39:1: error: stray '\240' in program sortsd.cpp:39:1: error: stray '\302' in program sortsd.cpp:39:1: error: stray '\240' in program sortsd.cpp:39:1: error: stray '\302' in program sortsd.cpp:39:1: error: stray '\240' in program sortsd.cpp:39:1: error: stray '\302' in program sortsd.cpp:39:1: error: stray '\240' in program sortsd.cpp:41:1: error: stray '\302' in program } ^ sortsd.cpp:41:1: error: stray '\240' in program sortsd.cpp:41:1: error: stray '\302' in program sortsd.cpp:41:1: error: stray '\240' in program sortsd.cpp:43:1: error: stray '\302' in program for (i=1; i<n; ++i) ^ sortsd.cpp:43:1: error: stray '\240' in program sortsd.cpp:43:1: error: stray '\302' in program sortsd.cpp:43:1: error: stray '\240' in program sortsd.cpp:45:1: error: stray '\302' in program { ^ sortsd.cpp:45:1: error: stray '\240' in program sortsd.cpp:45:1: error: stray '\302' in program sortsd.cpp:45:1: error: stray '\240' in program sortsd.cpp:47:1: error: stray '\302' in program for (j=i+1; j<=n; ++j) ^ sortsd.cpp:47:1: error: stray '\240' in program sortsd.cpp:47:1: error: stray '\302' in program sortsd.cpp:47:1: error: stray '\240' in program sortsd.cpp:47:1: error: stray '\302' in program sortsd.cpp:47:1: error: stray '\240' in program sortsd.cpp:47:1: error: stray '\302' in program sortsd.cpp:47:1: error: stray '\240' in program sortsd.cpp:49:1: error: stray '\302' in program { ^ sortsd.cpp:49:1: error: stray '\240' in program sortsd.cpp:49:1: error: stray '\302' in program sortsd.cpp:49:1: error: stray '\240' in program sortsd.cpp:49:1: error: stray '\302' in program sortsd.cpp:49:1: error: stray '\240' in program sortsd.cpp:49:1: error: stray '\302' in program sortsd.cpp:49:1: error: stray '\240' in program sortsd.cpp:51:1: error: stray '\302' in program if (sdiv[j]<sdiv[i]) ^ sortsd.cpp:51:1: error: stray '\240' in program sortsd.cpp:51:1: error: stray '\302' in program sortsd.cpp:51:1: error: stray '\240' in program sortsd.cpp:51:1: error: stray '\302' in program sortsd.cpp:51:1: error: stray '\240' in program sortsd.cpp:51:1: error: stray '\302' in program sortsd.cpp:51:1: error: stray '\240' in program sortsd.cpp:51:1: error: stray '\302' in program sortsd.cpp:51:1: error: stray '\240' in program sortsd.cpp:51:1: error: stray '\302' in program sortsd.cpp:51:1: error: stray '\240' in program sortsd.cpp:53:1: error: stray '\302' in program { ^ sortsd.cpp:53:1: error: stray '\240' in program sortsd.cpp:53:1: error: stray '\302' in program sortsd.cpp:53:1: error: stray '\240' in program sortsd.cpp:53:1: error: stray '\302' in program sortsd.cpp:53:1: error: stray '\240' in program sortsd.cpp:53:1: error: stray '\302' in program sortsd.cpp:53:1: error: stray '\240' in program sortsd.cpp:53:1: error: stray '\302' in program sortsd.cpp:53:1: error: stray '\240' in program sortsd.cpp:53:1: error: stray '\302' in program sortsd.cpp:53:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program swap(sdiv[i], sdiv[j]); ^ sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:55:1: error: stray '\302' in program sortsd.cpp:55:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program swap(v[i], v[j]); ^ sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:57:1: error: stray '\302' in program sortsd.cpp:57:1: error: stray '\240' in program sortsd.cpp:59:1: error: stray '\302' in program } ^ sortsd.cpp:59:1: error: stray '\240' in program sortsd.cpp:59:1: error: stray '\302' in program sortsd.cpp:59:1: error: stray '\240' in program sortsd.cpp:59:1: error: stray '\302' in program sortsd.cpp:59:1: error: stray '\240' in program sortsd.cpp:59:1: error: stray '\302' in program sortsd.cpp:59:1: error: stray '\240' in program sortsd.cpp:59:1: error: stray '\302' in program sortsd.cpp:59:1: error: stray '\240' in program sortsd.cpp:59:1: error: stray '\302' in program sortsd.cpp:59:1: error: stray '\240' in program sortsd.cpp:61:1: error: stray '\302' in program } ^ sortsd.cpp:61:1: error: stray '\240' in program sortsd.cpp:61:1: error: stray '\302' in program sortsd.cpp:61:1: error: stray '\240' in program sortsd.cpp:61:1: error: stray '\302' in program sortsd.cpp:61:1: error: stray '\240' in program sortsd.cpp:61:1: error: stray '\302' in program sortsd.cpp:61:1: error: stray '\240' in program sortsd.cpp:63:1: error: stray '\302' in program } ^ sortsd.cpp:63:1: error: stray '\240' in program sortsd.cpp:63:1: error: stray '\302' in program sortsd.cpp:63:1: error: stray '\240' in program sortsd.cpp:65:1: error: stray '\302' in program while (schimb==1) ^ sortsd.cpp:65:1: error: stray '\240' in program sortsd.cpp:65:1: error: stray '\302' in program sortsd.cpp:65:1: error: stray '\240' in program sortsd.cpp:67:1: error: stray '\302' in program { ^ sortsd.cpp:67:1: error: stray '\240' in program sortsd.cpp:67:1: error: stray '\302' in program sortsd.cpp:67:1: error: stray '\240' in program sortsd.cpp:69:1: error: stray '\302' in program schimb=0; ^ sortsd.cpp:69:1: error: stray '\240' in program sortsd.cpp:69:1: error: stray '\302' in program sortsd.cpp:69:1: error: stray '\240' in program sortsd.cpp:69:1: error: stray '\302' in program sortsd.cpp:69:1: error: stray '\240' in program sortsd.cpp:69:1: error: stray '\302' in program sortsd.cpp:69:1: error: stray '\240' in program sortsd.cpp:71:1: error: stray '\302' in program for (i=1; i<n; ++i) ^ sortsd.cpp:71:1: error: stray '\240' in program sortsd.cpp:71:1: error: stray '\302' in program sortsd.cpp:71:1: error: stray '\240' in program sortsd.cpp:71:1: error: stray '\302' in program sortsd.cpp:71:1: error: stray '\240' in program sortsd.cpp:71:1: error: stray '\302' in program sortsd.cpp:71:1: error: stray '\240' in program sortsd.cpp:73:1: error: stray '\302' in program { ^ sortsd.cpp:73:1: error: stray '\240' in program sortsd.cpp:73:1: error: stray '\302' in program sortsd.cpp:73:1: error: stray '\240' in program sortsd.cpp:73:1: error: stray '\302' in program sortsd.cpp:73:1: error: stray '\240' in program sortsd.cpp:73:1: error: stray '\302' in program sortsd.cpp:73:1: error: stray '\240' in program sortsd.cpp:75:1: error: stray '\302' in program if (sdiv[i]==sdiv[i+1] && v[i]>v[i+1]) { swap(v[i], v[i+1]); schimb=1; } ^ sortsd.cpp:75:1: error: stray '\240' in program sortsd.cpp:75:1: error: stray '\302' in program sortsd.cpp:75:1: error: stray '\240' in program sortsd.cpp:75:1: error: stray '\302' in program sortsd.cpp:75:1: error: stray '\240' in program sortsd.cpp:75:1: error: stray '\302' in program sortsd.cpp:75:1: error: stray '\240' in program sortsd.cpp:75:1: error: stray '\302' in program sortsd.cpp:75:1: error: stray '\240' in program sortsd.cpp:75:1: error: stray '\302' in program sortsd.cpp:75:1: error: stray '\240' in program sortsd.cpp:77:1: error: stray '\302' in program } ^ sortsd.cpp:77:1: error: stray '\240' in program sortsd.cpp:77:1: error: stray '\302' in program sortsd.cpp:77:1: error: stray '\240' in program sortsd.cpp:77:1: error: stray '\302' in program sortsd.cpp:77:1: error: stray '\240' in program sortsd.cpp:77:1: error: stray '\302' in program sortsd.cpp:77:1: error: stray '\240' in program sortsd.cpp:79:1: error: stray '\302' in program } ^ sortsd.cpp:79:1: error: stray '\240' in program sortsd.cpp:79:1: error: stray '\302' in program sortsd.cpp:79:1: error: stray '\240' in program sortsd.cpp:81:1: error: stray '\302' in program for (i=1; i<=n; ++i) ^ sortsd.cpp:81:1: error: stray '\240' in program sortsd.cpp:81:1: error: stray '\302' in program sortsd.cpp:81:1: error: stray '\240' in program sortsd.cpp:83:1: error: stray '\302' in program cout << v[i] << " "; ^ sortsd.cpp:83:1: error: stray '\240' in program sortsd.cpp:83:1: error: stray '\302' in program sortsd.cpp:83:1: error: stray '\240' in program sortsd.cpp:83:1: error: stray '\302' in program sortsd.cpp:83:1: error: stray '\240' in program sortsd.cpp:83:1: error: stray '\302' in program sortsd.cpp:83:1: error: stray '\240' in program
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema SortSD 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ă.