Sep 14, 2018

Find the most frequent number in the list in Python

test  =  [ 1 , 2 , 3 , 4 , 2 , 2 , 3 , 1 , 4 , 4 , 4 ]
print ( max ( set ( test ), key = test . count ))

# -> 4