Advertisement
furas

Python - TRUE LOVE

Jul 5th, 2018
323
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Python 0.43 KB | None | 0 0
  1. from collections import Counter
  2.  
  3. person1 = input("Input name of Person 1: ")
  4. person2 = input("Input name of Person 2: ")
  5.  
  6. a = Counter(person1)
  7. b = Counter(person2)
  8.  
  9. the_list = [ a[char] + b[char] for char in 'TRUELOVE' ]
  10. #print(the_list)
  11.  
  12. for _ in range(6):
  13.     pairs = list(zip(the_list, the_list[1:]))
  14.     print(pairs)
  15.  
  16.     the_list = [sum(x) % 10 for x in pairs]
  17.     print(the_list)
  18.  
  19. print(''.join(str(x) for x in the_list))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement