LogFAQs > #956094938

LurkerFAQs, Active DB, DB1, DB2, DB3, DB4, DB5, DB6, DB7, Database 8 ( 02.18.2021-09-28-2021 ), DB9, DB10, DB11, DB12, Clear
Topic List
Page List: 1
TopicITT: Learning Python
SomeLikeItHoth
07/14/21 11:58:07 PM
#80:


SpiritSephiroth posted...


Pretty sure I need to improve this code a bit since when running it, it doesn't work exactly the way I want it yet.
Here's how I ran it.

import random

roll_dice = True

while roll_dice:
print("Rolling the dice...")
print("The values are...")
print(random.randint(1, 6))

roll_again = input("Roll the dice again? (yes/no) ")
if roll_again == "yes":
roll_dice = True
else:
print("Goodbye!")
roll_dice = False

---
FAM FOREVER.
... Copied to Clipboard!
Topic List
Page List: 1