Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- # bronze
- num = int(input("How many bottles to start with?\n"))
- number = num
- for i in range(num):
- print(f'{number} green bottles, hanging on the wall')
- print(f'{number} green bottles hanging on the wall')
- print(f'and if one green bottle, should accidentally fall')
- number = number - 1
- print(f'there\'d be {number} green bottles, hanging on the wall')
- print()
- # silver
- num = int(input("How many bottles to start with?\n"))
- number = num
- for i in range(num):
- if number == 1:
- print(f'{number} green bottle, hanging on the wall')
- print(f'{number} green bottle hanging on the wall')
- else:
- print(f'{number} green bottles, hanging on the wall')
- print(f'{number} green bottles hanging on the wall')
- print(f'and if one green bottle, should accidentally fall')
- number = number - 1
- if number == 0:
- number = "no"
- if number == 1:
- print(f'there\'d be {number} green bottle, hanging on the wall')
- else:
- print(f'there\'d be {number} green bottles, hanging on the wall')
- print()
- # gold
- num = int(input("How many bottles to start with?\n"))
- number = num
- words = ["no", "one", "two", "three", "four", "five", "six", "seven", "eight", "nine", "ten"]
- for i in range(num):
- if number == 1:
- print(f'{words[number]} green bottle, hanging on the wall')
- print(f'{words[number]} green bottle hanging on the wall')
- else:
- print(f'{words[number]} green bottles, hanging on the wall')
- print(f'{words[number]} green bottles hanging on the wall')
- print(f'and if one green bottle, should accidentally fall')
- number = number - 1
- if number == 1:
- print(f'there\'d be {words[number]} green bottle, hanging on the wall')
- else:
- print(f'there\'d be {words[number]} green bottles, hanging on the wall')
- print()
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement