Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from itertools import product
- a = map(''.join, product('НИКОЛАЙ', repeat=4))
- words = []
- for i in a:
- if i[0] != 'Й' and ('И' in i or 'О' in i or 'А' in i):
- words.append(i)
- print(len(words))
Advertisement
Add Comment
Please, Sign In to add comment