Advertisement
zhukov000

08-1

Jun 24th, 2021
688
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.20 KB | None | 0 0
  1. from itertools import product
  2.  
  3. s = set()
  4. for t in product("ГЕПАРД", repeat=5):
  5.   st = "".join(t)
  6.   if st[0] != "А" and st[-1] != "Е" and st.count("Г") == 1:
  7.     s.add(st)
  8. print(len(s))
  9.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement