📜  在列表python代码示例中查找数字的频率

📅  最后修改于: 2022-03-11 14:46:41.142000             🧑  作者: Mango

代码示例2
from collections import Counter

def frequency_table(n):
    table = Counter(n)
    print('Number\tFrequency')
    for number in table.most_common() :
        print('{0}\t{1}'.format(number[0], number[1]))
        
# src : Doing Math With Python