#611
Un superstring este un şir infinit format din numere naturale nenule scrise fără spaţii între ele, începând cu 1
: 1223334444...1010...
(fiecare număr x
apare de exact x
ori).
Să se răspundă la T
întrebări de forma: Ce cifră se află în superstring pe poziţia k
?
Urmasii lui Moisil, 2014, Clasa a IX-a
Problema | superstring | Operații I/O |
![]() superstring.in /superstring.out
|
---|---|---|---|
Limita timp | 0.8 secunde | Limita memorie |
Total: 64 MB
/
Stivă 1 MB
|
Id soluție | #57639640 | Utilizator | |
Fișier | superstring.cpp | Dimensiune | 1.45 KB |
Data încărcării | 08 Aprilie 2025, 17:15 | Scor / rezultat | 0 puncte |
superstring.cpp: In function 'int main()': superstring.cpp:42:30: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] if (poz.first <= x && x <= poz.second) ^ superstring.cpp:42:44: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] if (poz.first <= x && x <= poz.second) ^ superstring.cpp:49:25: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] if (x < poz.first) ^ superstring.cpp:37:47: warning: variable 'end' set but not used [-Wunused-but-set-variable] int st = 1, dr = 1e9, nr = -1, begin, end; ^ superstring.cpp:59:24: warning: 'begin' may be used uninitialized in this function [-Wmaybe-uninitialized] fout << cif[(x - begin) % nrCif] << '\n'; ^
Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
---|---|---|---|---|---|---|
1 | 0 secunde | Raspuns gresit. | 5 | 0 | ||
2 | 0 secunde | Raspuns gresit. | 5 | 0 | ||
3 | 0.044 secunde | Raspuns gresit. | 5 | 0 | ||
4 | 0.132 secunde | Raspuns gresit. | 5 | 0 | ||
5 | 0.152 secunde | Raspuns gresit. | 5 | 0 | ||
6 | 0.192 secunde | Raspuns gresit. | 5 | 0 | ||
7 | 0.204 secunde | Raspuns gresit. | 5 | 0 | ||
8 | 0.224 secunde | Raspuns gresit. | 5 | 0 | ||
9 | 0.248 secunde | Raspuns gresit. | 5 | 0 | ||
10 | 0.268 secunde | Raspuns gresit. | 5 | 0 | ||
11 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
12 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
13 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
14 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
15 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
16 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
17 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
18 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
19 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
20 | 0.04 secunde | Raspuns gresit. | 5 | 0 | ||
Punctaj total | 0 |
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema superstring 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ă.