#2016
Vuli
Se cere să se afișeze în ordine crescătoare toate numerele fabuloase de pe linia k
a triunghiului.
Problema | Vuli | Operații I/O |
![]() vuli.in /vuli.out
|
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #51179208 | Utilizator | |
Fișier | vuli.cpp | Dimensiune | 805 B |
Data încărcării | 28 Mai 2024, 18:18 | Scor / rezultat | Eroare de compilare |
vuli.cpp: In function 'int main()': vuli.cpp:12:5: error: expected initializer before 'int' int sum=0; ^ vuli.cpp:13:11: error: 'num' was not declared in this scope while(num!=0) ^ vuli.cpp:15:9: error: 'sum' was not declared in this scope sum=sum+(num%10); ^ vuli.cpp:18:18: error: 'sum' was not declared in this scope int rad=sqrt(sum); ^ vuli.cpp:10:9: warning: unused variable 'a' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:16: warning: unused variable 'v' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:23: warning: unused variable 'i' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:25: warning: unused variable 'j' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:27: warning: unused variable 'n' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:29: warning: unused variable 'm' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:31: warning: unused variable 'k' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp:10:33: warning: unused variable 'sol' [-Wunused-variable] int a[100],v[100],i,j,n,m,k,sol[100]; ^ vuli.cpp: In function 'int main()': vuli.cpp:24:5: error: redefinition of 'int main()' int main() ^ vuli.cpp:7:5: error: 'int main()' previously defined here int main() ^ vuli.cpp:26:5: error: 'f' was not declared in this scope f>>n; ^ vuli.cpp:26:8: error: 'n' was not declared in this scope f>>n; ^ vuli.cpp:28:5: error: 'a' was not declared in this scope a[1]=1; ^ vuli.cpp:30:9: error: 'i' was not declared in this scope for(i=3;i<=n;i++) ^ vuli.cpp:32:13: error: 'j' was not declared in this scope for(j=1;j<=i;j++) ^ vuli.cpp:33:13: error: 'v' was not declared in this scope v[j]=a[j]+a[j-1]; ^ vuli.cpp:34:13: error: 'j' was not declared in this scope for(j=1;j<=i;j++) ^ vuli.cpp:35:18: error: 'v' was not declared in this scope a[j]=v[j]; ^ vuli.cpp:38:9: error: 'k' was not declared in this scope k=n/2; ^ vuli.cpp:40:9: error: 'k' was not declared in this scope k=(n+1)/2; ^ vuli.cpp:41:9: error: 'i' was not declared in this scope for(i=1;i<=k;i++) ^ vuli.cpp:41:16: error: 'k' was not declared in this scope for(i=1;i<=k;i++) ^ vuli.cpp:43:20: error: 'var' was not declared in this scope if(var(a[i])==1) ^ vuli.cpp:44:13: error: 'g' was not declared in this scope g<<a[i]<<" "; ^ vuli.cpp:46:13: error: expected '}' at end of input return 0; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema Vuli 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ă.