#3677
Se dau două numere naturale n și k. Determinați cea mai mare valoare care se poate obține eliminând din numărul n exact k cifre aflate pe poziții alăturate(una după alta).
Concursul Național Info Pro, Etapa II
| Problema | cifrevecine | Operații I/O |
cifrevecine.in/cifrevecine.out
|
|---|---|---|---|
| Limita timp | 0.1 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
| Id soluție | #63764691 | Utilizator | |
| Fișier | cifrevecine.cpp | Dimensiune | 449 B |
| Data încărcării | 18 Martie 2026, 09:59 | Scor/rezultat | Eroare de compilare |
cifrevecine.cpp:1:2: error: stray '#' in program v#include "bits/stdc++.h" ^ cifrevecine.cpp:1:1: error: 'v' does not name a type v#include "bits/stdc++.h" ^ cifrevecine.cpp:3:1: error: 'ifstream' does not name a type ifstream f("cifrevecine.in"); ^ cifrevecine.cpp:4:1: error: 'ofstream' does not name a type ofstream g("cifrevecine.out"); ^ cifrevecine.cpp: In function 'int main()': cifrevecine.cpp:8:1: error: 'f' was not declared in this scope f>>n>>k; ^ cifrevecine.cpp:10:1: error: 'n3' was not declared in this scope n3=0; ^ cifrevecine.cpp:15:1: error: 'v3' was not declared in this scope v3[n3]=b; ^ cifrevecine.cpp:18:1: error: 'n1' was not declared in this scope n1=0; ^ cifrevecine.cpp:22:1: error: 'v1' was not declared in this scope v1[n1]=v3[x]; ^ cifrevecine.cpp:22:8: error: 'v3' was not declared in this scope v1[n1]=v3[x]; ^ cifrevecine.cpp:25:5: error: 'y' was not declared in this scope for(y=1;y<=n1;y++) ^ cifrevecine.cpp:30:19: error: 'v1' was not declared in this scope if(x!=y) y1=y1*10+v1[x]; ^ cifrevecine.cpp:34:1: error: 'g' was not declared in this scope g<<max1; ^
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema cifrevecine 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ă.