1test = [1, 2, 3, 4, 2, 2, 3, 1, 4, 4, 4]
2print(max(set(test), key = test.count))
3
1class MyName:
2 Geeks, For, Geeks = range(3)
3
4print(MyName.Geeks)
5print(MyName.For)
6print(MyName.Geeks)
7
1from collections import Counter
2def is_anagram(str1, str2):
3 return Counter(str1) == Counter(str2)
4
5# or without having to import anything
6def is_anagram(str1, str2):
7 return sorted(str1) == sorted(str2)
8
9print(is_anagram('geek', 'eegk'))
10print(is_anagram('geek', 'peek'))
11