<div dir="ltr"><div class="gmail_extra"><br><div class="gmail_quote">On Thu, Dec 5, 2013 at 12:54 AM, Dario Bertini <span dir="ltr"><<a href="mailto:berdario@gmail.com" target="_blank">berdario@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
>>> def height(tree):<br>
... if len(tree) == 0:<br>
... return 1<br>
... else:<br>
... return 1+max(map(height, tree))<br></blockquote><div> </div><div><br></div><div>bello, molto elegante l'uso di map con la funzione ricorsiva.<br></div></div></div></div>