#2429
matrice9
Fie A
o matrice dreptunghiulară de numere întregi cu N
linii numerotate de la 1
la N
şi M
coloane numerotate de la 1
la M
. În matricea A
oricare două elemente consecutive de pe aceeaşi linie sunt distincte.
Se defineşte un şir valid de numere întregi ca fiind fie un şir crescător, fie un şir descrescător, fie un şir crescător concatenat cu un şir descrescător, fie un şir descrescător concatenat cu unul crescător. Exemple de şiruri valide sunt: 1 2 3 7
, 8 5 2 1
, 3 5 6 2
, 4 1 5 6
.Se defineşte o submatrice a lui A
de coordonate (l1
, c1
, l2
, c2
) ca fiind matricea formată din toate elementele A(i,j)
, cu l1 ≤ i ≤ l2
şi c1 ≤ j ≤ c2
. O submatrice a lui A
este validă dacă liniile sale sunt şiruri valide.
Atenţie! O submatrice validă poate avea pe o linie un şir crescător de numere, pe a doua un şir descrescător, pe a treia un şir crescător concatenat cu unul descrescător etc. Deci, liniile unei submatrice valide nu trebuie să fie neapărat şiruri de acelaşi tip.
Aria unei submatrice este egală cu numărul de elemente din care este formată submatricea. Se cere să se găsească o submatrice validă a lui A
de arie maximă.
Problema | matrice9 | Operații I/O |
matrice9.in /matrice9.out
|
---|---|---|---|
Limita timp | 0.2 secunde | Limita memorie |
Total: 64 MB
/
Stivă 8 MB
|
Id soluție | #50318650 | Utilizator | |
Fișier | matrice9.cpp | Dimensiune | 4.62 KB |
Data încărcării | 04 Aprilie 2024, 12:54 | Scor / rezultat | Eroare de compilare |
matrice9.cpp:1:1: error: stray '\304' in program Rezolvări ^ matrice9.cpp:1:1: error: stray '\203' in program matrice9.cpp:2431:1: error: stray '\304' in program matrice9.cpp:2431:1: error: stray '\203' in program matrice9.cpp:2431:1: error: stray '\303' in program matrice9.cpp:2431:1: error: stray '\256' in program matrice9.cpp:2431:1: error: stray '\305' in program matrice9.cpp:2431:1: error: stray '\237' in program matrice9.cpp:2431:1: error: stray '\303' in program matrice9.cpp:2431:1: error: stray '\216' in program matrice9.cpp:2431:1: error: stray '\304' in program matrice9.cpp:2431:1: error: stray '\203' in program matrice9.cpp:2431:1: error: stray '\305' in program matrice9.cpp:2431:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\303' in program matrice9.cpp:2432:1: error: stray '\256' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\304' in program matrice9.cpp:2432:1: error: stray '\203' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\304' in program matrice9.cpp:2432:1: error: stray '\203' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\304' in program matrice9.cpp:2432:1: error: stray '\203' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\304' in program matrice9.cpp:2432:1: error: stray '\203' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2432:1: error: stray '\304' in program matrice9.cpp:2432:1: error: stray '\203' in program matrice9.cpp:2432:1: error: stray '\304' in program matrice9.cpp:2432:1: error: stray '\203' in program matrice9.cpp:2432:1: error: stray '\305' in program matrice9.cpp:2432:1: error: stray '\237' in program matrice9.cpp:2433:1: error: stray '\305' in program matrice9.cpp:2433:1: error: stray '\237' in program matrice9.cpp:2433:1: error: stray '\304' in program matrice9.cpp:2433:1: error: stray '\203' in program matrice9.cpp:2433:1: error: stray '\342' in program matrice9.cpp:2433:1: error: stray '\211' in program matrice9.cpp:2433:1: error: stray '\244' in program matrice9.cpp:2433:1: error: stray '\342' in program matrice9.cpp:2433:1: error: stray '\211' in program matrice9.cpp:2433:1: error: stray '\244' in program matrice9.cpp:2433:1: error: stray '\305' in program matrice9.cpp:2433:1: error: stray '\237' in program matrice9.cpp:2433:1: error: stray '\342' in program matrice9.cpp:2433:1: error: stray '\211' in program matrice9.cpp:2433:1: error: stray '\244' in program matrice9.cpp:2433:1: error: stray '\342' in program matrice9.cpp:2433:1: error: stray '\211' in program matrice9.cpp:2433:1: error: stray '\244' in program matrice9.cpp:2434:1: error: stray '\304' in program matrice9.cpp:2434:1: error: stray '\203' in program matrice9.cpp:2434:1: error: stray '\304' in program matrice9.cpp:2434:1: error: stray '\203' in program matrice9.cpp:2434:1: error: stray '\305' in program matrice9.cpp:2434:1: error: stray '\237' in program matrice9.cpp:2435:1: error: stray '\305' in program matrice9.cpp:2435:1: error: stray '\243' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\305' in program matrice9.cpp:2435:1: error: stray '\237' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\305' in program matrice9.cpp:2435:1: error: stray '\237' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\305' in program matrice9.cpp:2435:1: error: stray '\237' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\304' in program matrice9.cpp:2435:1: error: stray '\203' in program matrice9.cpp:2435:1: error: stray '\305' in program matrice9.cpp:2435:1: error: stray '\237' in program matrice9.cpp:2435:1: error: stray '\305' in program matrice9.cpp:2435:1: error: stray '\237' in program matrice9.cpp:2436:1: error: stray '\304' in program matrice9.cpp:2436:1: error: stray '\203' in program matrice9.cpp:2436:1: error: stray '\304' in program matrice9.cpp:2436:1: error: stray '\203' in program matrice9.cpp:2436:1: error: stray '\304' in program matrice9.cpp:2436:1: error: stray '\203' in program matrice9.cpp:2438:1: error: stray '\310' in program matrice9.cpp:2438:1: error: stray '\233' in program matrice9.cpp:2439:1: error: stray '\304' in program matrice9.cpp:2439:1: error: stray '\203' in program matrice9.cpp:2439:1: error: stray '\304' in program matrice9.cpp:2439:1: error: stray '\203' in program matrice9.cpp:2439:1: error: stray '\304' in program matrice9.cpp:2439:1: error: stray '\203' in program matrice9.cpp:2439:1: error: stray '\304' in program matrice9.cpp:2439:1: error: stray '\203' in program matrice9.cpp:2439:1: error: stray '\304' in program matrice9.cpp:2439:1: error: stray '\203' in program matrice9.cpp:2442:1: error: stray '\310' in program matrice9.cpp:2442:1: error: stray '\231' in program matrice9.cpp:2442:1: error: stray '\310' in program matrice9.cpp:2442:1: error: stray '\233' in program matrice9.cpp:2442:1: error: stray '\305' in program matrice9.cpp:2442:1: error: stray '\237' in program matrice9.cpp:2442:1: error: stray '\305' in program matrice9.cpp:2442:1: error: stray '\243' in program matrice9.cpp:2442:1: error: stray '\304' in program matrice9.cpp:2442:1: error: stray '\203' in program matrice9.cpp:2442:1: error: stray '\304' in program matrice9.cpp:2442:1: error: stray '\203' in program matrice9.cpp:2442:1: error: stray '\303' in program matrice9.cpp:2442:1: error: stray '\242' in program matrice9.cpp:2442:1: error: stray '\303' in program matrice9.cpp:2442:1: error: stray '\256' in program matrice9.cpp:2442:1: error: stray '\303' in program matrice9.cpp:2442:1: error: stray '\242' in program matrice9.cpp:2442:1: error: stray '\305' in program matrice9.cpp:2442:1: error: stray '\243' in program matrice9.cpp:2442:1: error: stray '\303' in program matrice9.cpp:2442:1: error: stray '\242' in program matrice9.cpp:2444:1: error: stray '\310' in program matrice9.cpp:2444:1: error: stray '\231' in program matrice9.cpp:2445:1: error: stray '\310' in program matrice9.cpp:2445:1: error: stray '\231' in program matrice9.cpp:2445:1: error: stray '\310' in program matrice9.cpp:2445:1: error: stray '\231' in program matrice9.cpp:2445:1: error: stray '\305' in program matrice9.cpp:2445:1: error: stray '\243' in program matrice9.cpp:2445:1: error: stray '\304' in program matrice9.cpp:2445:1: error: stray '\203' in program matrice9.cpp:2445:1: error: stray '\303' in program matrice9.cpp:2445:1: error: stray '\256' in program matrice9.cpp:2445:1: error: stray '\304' in program matrice9.cpp:2445:1: error: stray '\203' in program matrice9.cpp:2445:1: error: stray '\305' in program matrice9.cpp:2445:1: error: stray '\237' in program matrice9.cpp:2445:1: error: stray '\303' in program matrice9.cpp:2445:1: error: stray '\242' in program matrice9.cpp:2445:1: error: stray '\305' in program matrice9.cpp:2445:1: error: stray '\243' in program matrice9.cpp:2445:1: error: stray '\304' in program matrice9.cpp:2445:1: error: stray '\203' in program matrice9.cpp:2445:1: error: stray '\303' in program matrice9.cpp:2445:1: error: stray '\216' in program matrice9.cpp:2445:1: error: stray '\303' in program matrice9.cpp:2445:1: error: stray '\256' in program matrice9.cpp:2445:1: error: stray '\304' in program matrice9.cpp:2445:1: error: stray '\203' in program matrice9.cpp:2445:1: error: stray '\305' in program matrice9.cpp:2445:1: error: stray '\243' in program matrice9.cpp:2445:1: error: stray '\304' in program matrice9.cpp:2445:1: error: stray '\203' in program matrice9.cpp:2445:1: error: stray '\305' in program matrice9.cpp:2445:1: error: stray '\237' in program matrice9.cpp:2447:1: error: stray '\310' in program matrice9.cpp:2447:1: error: stray '\233' in program matrice9.cpp:2447:1: error: stray '\310' in program matrice9.cpp:2447:1: error: stray '\231' in program matrice9.cpp:2447:1: error: stray '\304' in program matrice9.cpp:2447:1: error: stray '\203' in program matrice9.cpp:2448:1: error: stray '\342' in program matrice9.cpp:2448:1: error: stray '\211' in program matrice9.cpp:2448:1: error: stray '\244' in program matrice9.cpp:2448:1: error: stray '\342' in program matrice9.cpp:2448:1: error: stray '\211' in program matrice9.cpp:2448:1: error: stray '\244' in program matrice9.cpp:2449:1: error: stray '\342' in program matrice9.cpp:2449:1: error: stray '\211' in program matrice9.cpp:2449:1: error: stray '\244' in program matrice9.cpp:2450:1: error: stray '\303' in program matrice9.cpp:2450:1: error: stray '\256' in program matrice9.cpp:2461:1: error: stray '\310' in program matrice9.cpp:2461:1: error: stray '\233' in program matrice9.cpp:2462:1: error: stray '\304' in program matrice9.cpp:2462:1: error: stray '\203' in program matrice9.cpp:2462:1: error: stray '\304' in program matrice9.cpp:2462:1: error: stray '\203' in program matrice9.cpp:2462:1: error: stray '\305' in program matrice9.cpp:2462:1: error: stray '\243' in program matrice9.cpp:2462:1: error: stray '\304' in program matrice9.cpp:2462:1: error: stray '\203' in program matrice9.cpp:2469:1: error: stray '\304' in program matrice9.cpp:2469:1: error: stray '\203' in program matrice9.cpp:1:1: error: 'Rezolv' does not name a type Rezolvări ^ matrice9.cpp:2466:1: error: 'cout' does not name a type matrice9.cpp:2467:1: error: 'cout' does not name a type matrice9.cpp:2468:1: error: 'Rezolvare' does not name a type cc1plus: out of memory allocating 1677721600 bytes after a total of 1761280 bytes
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema matrice9 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ă.