#4825
HeavyLightDecomposition
Se dă un arbore cu \(N\) noduri înrădăcinat în nodul \(1\), unde fiecare nod are un pondere asociat întreg \(V_i\). Să se proceseze \(Q\) evenimente de următoarele \(3\) tipuri:
Problema | HeavyLightDecomposition | Operații I/O |
![]() |
---|---|---|---|
Limita timp | 0.8 secunde | Limita memorie |
Total: 128 MB
/
Stivă 128 MB
|
Id soluție | #57926791 | Utilizator | |
Fișier | heavylightdecomposition.java | Dimensiune | 6.17 KB |
Data încărcării | 02 Mai 2025, 12:16 | Scor / rezultat | 50 puncte |
Note: heavylightdecomposition.java uses unchecked or unsafe operations. Note: Recompile with -Xlint:unchecked for details.
Test | Timp | Mesaj evaluare | Scor posibil | Scor obținut | ||
---|---|---|---|---|---|---|
1 | 0.24 secunde | Exited with error status 1 | 5 | 0 | ||
2 | 0.284 secunde | Exited with error status 1 | 5 | 0 | ||
3 | 0.604 secunde | OK. | 5 | 5 | ||
4 | 0.764 secunde | OK. | 5 | 5 | ||
5 | 0.448 secunde | Exited with error status 1 | 5 | 0 | ||
6 | 0.492 secunde | Exited with error status 1 | 5 | 0 | ||
7 | 0.588 secunde | Exited with error status 1 | 5 | 0 | ||
8 | 1.436 secunde | OK. | 5 | 5 | ||
9 | 0.708 secunde | Exited with error status 1 | 5 | 0 | ||
10 | 0.704 secunde | Exited with error status 1 | 5 | 0 | ||
11 | 2.032 secunde | OK. | 5 | 5 | ||
12 | 2.132 secunde | OK. | 5 | 5 | ||
13 | 2.324 secunde | OK. | 5 | 5 | ||
14 | 0.884 secunde | Exited with error status 1 | 5 | 0 | ||
15 | 2.38 secunde | OK. | 5 | 5 | ||
16 | 2.664 secunde | OK. | 5 | 5 | ||
17 | 1.084 secunde | Exited with error status 1 | 5 | 0 | ||
18 | 1.232 secunde | Exited with error status 1 | 5 | 0 | ||
19 | 3.008 secunde | OK. | 5 | 5 | ||
20 | 3.28 secunde | OK. | 5 | 5 | ||
Punctaj total | 50 |
www.pbinfo.ro permite evaluarea a două tipuri de probleme:
Problema HeavyLightDecomposition 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ă.