View: operar listas

  1. 9 years ago by macks
    1. values = ['Enero','Enero','Enero','Febrero']
    2. print  [(x,values.count(x)) for x in set(values)]
    3.  
    4. ====>>[('Enero', 3), ('Febrero', 1)]
    Paste this in your website: <script type="text/javascript" src="http://www.posteet.com/embed/2055"></script>

0 comment about "operar listas"