Afişează mesaje
|
Pagini: [1]
|
3
|
infoarena - concursuri, probleme, evaluator, articole / Arhiva educationala / Răspuns: 007 Arbori de intervale
|
: Aprilie 03, 2014, 13:53:52
|
Pai fiind un arbore binar echilibrat, ai 1 nod(radacina), cu 2 fii, urmati de 4 noduri, 8 etc, pana la ultimul nivel unde ai fix N noduri. Asta e egal cu 20 + 21 + 22 ... +2X = 2X+1 - 1, unde 2X = N. 2X+1 = 2 * 2X = 2 * N. Deci un 3 * N ar trebui sa ajunga(pentru ultimul nivel, incomplet).
|
|
|
5
|
Comunitate - feedback, proiecte si distractie / Blog / Răspuns: Fox Hunting
|
: Septembrie 04, 2012, 18:17:41
|
I have found the solution of iterating through hole 2-10 twice(I read the comments after and saw the other similar response). Don't know if it is truly correct but I tried it against 10 billion random tests and it worked for every single one.
|
|
|
|