learningpython/magic_8.py

19 lines
348 B
Python
Raw Normal View History

2021-02-08 18:29:13 +01:00
#! /usr/bin/env python3
import random
def getAwnser():
r = random.randint(0, 8)
messages = ['It is certain',
'It is decidedly so',
'Yes',
'Reply hazy, try again',
'Ask again later',
'My reply is no',
'Outlook not so good',
'Very doubtful' ]
return messages[r]
for i in range(0,10):
print(getAwnser())