Detalii evaluare #53372774

Rezumat problemă

Moș Crăciun însa dorește să le mai aducă zâmbetul pe buze și de aceea a decis să ducă fiecărei case câte o sticlă de șampanie deoarece deși oamenii de aici au bani, nu au magazine de unde să cumpere. Însă din păcate Moș Crăciun este bătrân și nu poate transporta prea multe sticle așa că decide să distribuie câte o sticla de șampanie la fiecare două case. Pentru simplitate Moș Crăciun a făcut o hartă a caselor în care o casă este notată cu 1 și pământul gol cu 0. Moș Crăciun însă nu prea le are cu programarea și de aceea vă roagă să îl ajutați!

Scrieți un program care primind harta caselor afișează câte sticle de șampanie trebuie să aducă Moș Crăciun.

Detalii

Problema Merry Cristmas Operații I/O tastatură/ecran
Limita timp 0.3 secunde Limita memorie Total: 64 MB / Stivă 8 MB
Id soluție #53372774 Utilizator Petre Eric Mihai (erice12345)
Fișier merry_cristmas.cpp Dimensiune 1.74 KB
Data încărcării 26 Octombrie 2024, 14:46 Scor / rezultat Eroare de compilare

Evaluare


Mesaj compilare

merry_cristmas.cpp:1:1: error: stray '\303' in program
 Într-un ținut îndepărtat cu peisaje de poveste pacea domnește peste întreg ținutul deoarece lumea are absolut tot ce îi trebuie.

 ^
merry_cristmas.cpp:1:1: error: stray '\216' in program
merry_cristmas.cpp:1:1: error: stray '\310' in program
merry_cristmas.cpp:1:1: error: stray '\233' in program
merry_cristmas.cpp:1:1: error: stray '\303' in program
merry_cristmas.cpp:1:1: error: stray '\256' in program
merry_cristmas.cpp:1:1: error: stray '\304' in program
merry_cristmas.cpp:1:1: error: stray '\203' in program
merry_cristmas.cpp:1:1: error: stray '\310' in program
merry_cristmas.cpp:1:1: error: stray '\231' in program
merry_cristmas.cpp:1:1: error: stray '\303' in program
merry_cristmas.cpp:1:1: error: stray '\256' in program
merry_cristmas.cpp:1:1: error: stray '\310' in program
merry_cristmas.cpp:1:1: error: stray '\233' in program
merry_cristmas.cpp:1:1: error: stray '\303' in program
merry_cristmas.cpp:1:1: error: stray '\256' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
 Moș Crăciun însa dorește să le mai aducă zâmbetul pe buze și de aceea a decis să ducă fiecărei case câte o sticlă de șampanie deoarece deși oamenii de aici au bani, nu au magazine de unde să cumpere. Însă din păcate Moș Crăciun este bătrân și nu poate transporta prea multe sticle așa că decide să distribuie câte o sticla de șampanie la fiecare două case. Pentru simplitate Moș Crăciun a făcut o hartă a caselor în care o casă este notată cu 1 și pământul gol cu 0. Moș Crăciun însă nu prea le are cu programarea și de aceea vă roagă să îl ajutați!

 ^
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\256' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\242' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\242' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\216' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\242' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\242' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\256' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\242' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\256' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\231' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\304' in program
merry_cristmas.cpp:3:1: error: stray '\203' in program
merry_cristmas.cpp:3:1: error: stray '\303' in program
merry_cristmas.cpp:3:1: error: stray '\256' in program
merry_cristmas.cpp:3:1: error: stray '\310' in program
merry_cristmas.cpp:3:1: error: stray '\233' in program
merry_cristmas.cpp:5:1: error: stray '\310' in program
 Scrieți un program care primind harta caselor afișează câte sticle de șampanie trebuie să aducă Moș Crăciun.

 ^
merry_cristmas.cpp:5:1: error: stray '\233' in program
merry_cristmas.cpp:5:1: error: stray '\310' in program
merry_cristmas.cpp:5:1: error: stray '\231' in program
merry_cristmas.cpp:5:1: error: stray '\304' in program
merry_cristmas.cpp:5:1: error: stray '\203' in program
merry_cristmas.cpp:5:1: error: stray '\303' in program
merry_cristmas.cpp:5:1: error: stray '\242' in program
merry_cristmas.cpp:5:1: error: stray '\310' in program
merry_cristmas.cpp:5:1: error: stray '\231' in program
merry_cristmas.cpp:5:1: error: stray '\304' in program
merry_cristmas.cpp:5:1: error: stray '\203' in program
merry_cristmas.cpp:5:1: error: stray '\304' in program
merry_cristmas.cpp:5:1: error: stray '\203' in program
merry_cristmas.cpp:5:1: error: stray '\310' in program
merry_cristmas.cpp:5:1: error: stray '\231' in program
merry_cristmas.cpp:5:1: error: stray '\304' in program
merry_cristmas.cpp:5:1: error: stray '\203' in program
merry_cristmas.cpp:8:1: error: stray '\304' in program
 Programul va citi un număr natural n de pe prima linie și de pe a doua linie n numere naturale din intervalul [0;1].

 ^
merry_cristmas.cpp:8:1: error: stray '\203' in program
merry_cristmas.cpp:8:1: error: stray '\310' in program
merry_cristmas.cpp:8:1: error: stray '\231' in program
merry_cristmas.cpp:11:1: error: stray '\310' in program
 Date de ieșire

 ^
merry_cristmas.cpp:11:1: error: stray '\231' in program
merry_cristmas.cpp:12:1: error: stray '\310' in program
 Programul va afișa numărul s de sticle necesare

 ^
merry_cristmas.cpp:12:1: error: stray '\231' in program
merry_cristmas.cpp:12:1: error: stray '\304' in program
merry_cristmas.cpp:12:1: error: stray '\203' in program
merry_cristmas.cpp:14:1: error: stray '\310' in program
 Restricții și precizări

 ^
merry_cristmas.cpp:14:1: error: stray '\233' in program
merry_cristmas.cpp:14:1: error: stray '\310' in program
merry_cristmas.cpp:14:1: error: stray '\231' in program
merry_cristmas.cpp:14:1: error: stray '\304' in program
merry_cristmas.cpp:14:1: error: stray '\203' in program
merry_cristmas.cpp:15:1: error: stray '\342' in program
 1 ≤ n ≤ 1.000.000

 ^
merry_cristmas.cpp:15:1: error: stray '\211' in program
merry_cristmas.cpp:15:1: error: stray '\244' in program
merry_cristmas.cpp:15:1: error: stray '\342' in program
merry_cristmas.cpp:15:1: error: stray '\211' in program
merry_cristmas.cpp:15:1: error: stray '\244' in program
merry_cristmas.cpp:15:13: error: too many decimal points in number
 1 ≤ n ≤ 1.000.000

             ^
merry_cristmas.cpp:17:1: error: stray '\310' in program
 desigur șampania oferită de Moș Crăciun este una fără alcool

 ^
merry_cristmas.cpp:17:1: error: stray '\231' in program
merry_cristmas.cpp:17:1: error: stray '\304' in program
merry_cristmas.cpp:17:1: error: stray '\203' in program
merry_cristmas.cpp:17:1: error: stray '\310' in program
merry_cristmas.cpp:17:1: error: stray '\231' in program
merry_cristmas.cpp:17:1: error: stray '\304' in program
merry_cristmas.cpp:17:1: error: stray '\203' in program
merry_cristmas.cpp:17:1: error: stray '\304' in program
merry_cristmas.cpp:17:1: error: stray '\203' in program
merry_cristmas.cpp:17:1: error: stray '\304' in program
merry_cristmas.cpp:17:1: error: stray '\203' in program
merry_cristmas.cpp:18:1: error: stray '\304' in program
 oricare două case sunt prietene și nu există pereche de case care să refuze șampania

 ^
merry_cristmas.cpp:18:1: error: stray '\203' in program
merry_cristmas.cpp:18:1: error: stray '\310' in program
merry_cristmas.cpp:18:1: error: stray '\231' in program
merry_cristmas.cpp:18:1: error: stray '\304' in program
merry_cristmas.cpp:18:1: error: stray '\203' in program
merry_cristmas.cpp:18:1: error: stray '\304' in program
merry_cristmas.cpp:18:1: error: stray '\203' in program
merry_cristmas.cpp:18:1: error: stray '\310' in program
merry_cristmas.cpp:18:1: error: stray '\231' in program
merry_cristmas.cpp:24:1: error: stray '\310' in program
 Ieșire

 ^
merry_cristmas.cpp:24:1: error: stray '\231' in program
merry_cristmas.cpp:27:1: error: stray '\310' in program
 Explicație

 ^
merry_cristmas.cpp:27:1: error: stray '\233' in program
merry_cristmas.cpp:28:1: error: stray '\304' in program
 Există 6 perechi de case ce vor primi sticla de șampanie cele cu indici 1 și 4 , 1 și 6 , 1 și 7 , 4 și 6 , 4 și 7 , 6 și 7.

 ^
merry_cristmas.cpp:28:1: error: stray '\203' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:28:1: error: stray '\310' in program
merry_cristmas.cpp:28:1: error: stray '\231' in program
merry_cristmas.cpp:30:1: error: stray '\303' in program
 Încărcare soluție

 ^
merry_cristmas.cpp:30:1: error: stray '\216' in program
merry_cristmas.cpp:30:1: error: stray '\304' in program
merry_cristmas.cpp:30:1: error: stray '\203' in program
merry_cristmas.cpp:30:1: error: stray '\310' in program
merry_cristmas.cpp:30:1: error: stray '\233' in program
merry_cristmas.cpp:32:1: error: stray '\310' in program
 Lipește codul aici

 ^
merry_cristmas.cpp:32:1: error: stray '\231' in program
merry_cristmas.cpp:37:1: error: stray '\342' in program

 ^
merry_cristmas.cpp:37:1: error: stray '\200' in program
merry_cristmas.cpp:37:1: error: stray '\213' in program
merry_cristmas.cpp:38:2: error: stray '\342' in program
  Contact •  Reîncarcă • 2a02:2f0c:e306:db00:5006:251b:2eab:5071

  ^
merry_cristmas.cpp:38:2: error: stray '\200' in program
merry_cristmas.cpp:38:2: error: stray '\242' in program
merry_cristmas.cpp:38:2: error: stray '\303' in program
merry_cristmas.cpp:38:2: error: stray '\256' in program
merry_cristmas.cpp:38:2: error: stray '\304' in program
merry_cristmas.cpp:38:2: error: stray '\203' in program
merry_cristmas.cpp:38:2: error: stray '\342' in program
merry_cristmas.cpp:38:2: error: stray '\200' in program
merry_cristmas.cpp:38:2: error: stray '\242' in program
merry_cristmas.cpp:38:61: error: exponent has no digits
  Contact •  Reîncarcă • 2a02:2f0c:e306:db00:5006:251b:2eab:5071

                                                             ^
merry_cristmas.cpp:1:3: error: 'ntr' does not name a type
 Într-un ținut îndepărtat cu peisaje de poveste pacea domnește peste întreg ținutul deoarece lumea are absolut tot ce îi trebuie.

   ^
merry_cristmas.cpp:8:116: error: expected unqualified-id before numeric constant
 Programul va citi un număr natural n de pe prima linie și de pe a doua linie n numere naturale din intervalul [0;1].

                                                                                                                    ^
merry_cristmas.cpp:16:47: error: expected unqualified-id before numeric constant
 cele n numere citite vor fi din intervalul [0;1]

                                               ^

Cum funcționează evaluarea?

www.pbinfo.ro permite evaluarea a două tipuri de probleme:

  • probleme la care rezolvarea presupune scrierea unui program complet
  • probleme la care rezolvarea presupune scrierea unei secvențe de program - câteva instrucțiuni, o listă de declarații, una sau mai multe funcții, etc.

Problema Merry Cristmas face parte din prima categorie. Soluția propusă de tine va fi evaluată astfel:

  • Programul sursă este compilat folosind compilatorul corespunzător. Dacă în urma compilării se obțin erori sau avertismente, acestea sunt afișate în această pagină.
  • Dacă programul a fost compilat, executabilul obținut va fi rulat, furnizându-i-se unul sau mai multe seturi de date de intrare, în concordanță cu restricțiile specifice problemei. Pentru fiecare set de date se obține un anumit punctaj, în raport cu corectitudinea soluției tale.

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ă.