#1883
UEMM
Se dă un șir cu n
elemente, numere naturale. Să se afișeze, pentru fiecare element din șir, valoarea din șir aflată după acesta și mai mare decât acesta. Dacă o asemenea valoare nu există, se va afișa -1
.
Problema | UEMM | Operații I/O | tastatură/ecran |
---|---|---|---|
Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #38037017 | Utilizator | |
Fișier | uemm.cpp | Dimensiune | 1001 B |
Data încărcării | 28 Septembrie 2022, 08:20 | Scor / rezultat | Eroare de compilare |
uemm.cpp:1:7: error: expected nested-name-specifier before 'System' using System; ^ uemm.cpp:1:7: error: 'System' has not been declared uemm.cpp:2:7: error: expected nested-name-specifier before 'System' using System.Collections.Generic; ^ uemm.cpp:2:7: error: 'System' has not been declared uemm.cpp:2:13: error: expected ';' before '.' token using System.Collections.Generic; ^ uemm.cpp:2:13: error: expected unqualified-id before '.' token uemm.cpp:3:7: error: expected nested-name-specifier before 'System' using System.Linq; ^ uemm.cpp:3:7: error: 'System' has not been declared uemm.cpp:3:13: error: expected ';' before '.' token using System.Linq; ^ uemm.cpp:3:13: error: expected unqualified-id before '.' token uemm.cpp:4:7: error: expected nested-name-specifier before 'System' using System.Text; ^ uemm.cpp:4:7: error: 'System' has not been declared uemm.cpp:4:13: error: expected ';' before '.' token using System.Text; ^ uemm.cpp:4:13: error: expected unqualified-id before '.' token uemm.cpp:5:7: error: expected nested-name-specifier before 'System' using System.Threading.Tasks; ^ uemm.cpp:5:7: error: 'System' has not been declared uemm.cpp:5:13: error: expected ';' before '.' token using System.Threading.Tasks; ^ uemm.cpp:5:13: error: expected unqualified-id before '.' token uemm.cpp:11:26: error: 'string' has not been declared static void Main(string[] args) ^ uemm.cpp:11:35: error: expected ',' or '...' before 'args' static void Main(string[] args) ^ uemm.cpp:38:5: error: expected ';' after class definition } ^ uemm.cpp: In static member function 'static void p29_test::Program::Main(int*)': uemm.cpp:14:16: error: expected unqualified-id before '[' token int[] a; ^ uemm.cpp:15:13: error: 'string' was not declared in this scope string s; ^ uemm.cpp:15:20: error: expected ';' before 's' string s; ^ uemm.cpp:16:20: error: expected primary-expression before ']' token string[] nr; ^ uemm.cpp:16:22: error: expected ';' before 'nr' string[] nr; ^ uemm.cpp:18:17: error: expected primary-expression before 'int' n = int.Parse(Console.ReadLine()); ^ uemm.cpp:18:17: error: expected ';' before 'int' uemm.cpp:19:13: error: 's' was not declared in this scope s = Console.ReadLine(); ^ uemm.cpp:19:17: error: 'Console' was not declared in this scope s = Console.ReadLine(); ^ uemm.cpp:20:13: error: 'nr' was not declared in this scope nr = s.Split(' '); ^ uemm.cpp:21:13: error: 'a' was not declared in this scope a = new int[n]; ^ uemm.cpp:23:24: error: expected primary-expression before 'int' a[i] = int.Parse(nr[i]); ^ uemm.cpp:23:24: error: expected ';' before 'int'
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema UEMM 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ă.