Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from random import randint
- import sys, time
- zahl_gefunden = False
- while not(zahl_gefunden):
- zahl = randint(1,100)
- checker = zahl % 5
- if zahl >= 60 and zahl <= 70:
- zahl = 69
- print(zahl)
- zahl_gefunden = True
- elif checker == 0:
- print(zahl)
- zahl_gefunden = True
- def delay_print(text):
- for i in range(len(text)):
- sys.stdout.write(text[i])
- sys.stdout.flush()
- time.sleep(0.10)
- def pokemon_print(satz):
- inhalt = satz.split(" ")
- for i in range(len(inhalt)):
- delay_print(inhalt[i])
- sys.stdout.write(" ")
- time.sleep(0.9)
- pokemon_print("Das ist ein Test")
- vorbei = False
- while not(vorbei):
- eingabe = input("Zahl: ")
- try:
- int(eingabe)
- except:
- print("Keine Zahl!")
- continue
- eingabe = int(eingabe) * int(eingabe)
- print(eingabe)
- break
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement