Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- catNames = []
- while True:
- print('Enter the name of cat ' + str(len(catNames) + 1) +
- ' (or enter nothing to stop.):')
- name = input()
- if name == '':
- break
- catNames = catNames + [name] # List concatenation
- print('The cat names are:')
- for name in catNames:
- print(' ' + name)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement