30-07-2010, 06:46 PM
En Scala :
Code PHP :
<?php
var map = Map ("toto" -> 30, "tutu" -> 26, "zzz" -> 14, "aaaa" -> 56, "lolita" -> 3)
map.reduceLeft {(a,b) => if (a._2 > b._2) b else a }