Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import random
- randomarray = list()
- def lottery(ranging,countofnumber):
- random.seed()
- randomarray=random.sample(range(1, ranging+1), countofnumber)
- if randomarray[0]>=100:
- return 0
- return (randomarray)[0]
- def symbol(ranging = 20)->int:
- random.seed()
- arrayofsymbol = ["none","nap","autó","hal","gomba","alma","óra","horgony","hold","ház","bagoly","virág","szőlő","labda","zászló","csillag","gyémánt","könyv","pálmafa","sziv","bögre"]
- temp = random.sample(range(1,ranging+1),1)[0]
- return str(temp).zfill(2), arrayofsymbol[temp]
- print("Napi mázli","Év: ", str(lottery(100,1)).zfill(2),"Hónap: ",str(lottery(12,1)).zfill(2),"Nap: ",str(lottery(31,1)).zfill(2),"Szimbolum: ",symbol())
- print("Több tippet kér? Adja meg a számot, hogy mennyit!")
- countoftip = input("Tippek száma: ")
- if (countoftip.isnumeric()):
- for i in range (int(countoftip)):
- print(i+1,"Napi mázli","Év: ", str(lottery(100,1)).zfill(2),"Hónap: ",str(lottery(12,1)).zfill(2),"Nap: ",str(lottery(31,1)).zfill(2),"Szimbolum: ",symbol())
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement