Jan-05-2019, 06:38 PM
okey but the problem is that i cant get it go give diffrent cards(random) to the players. it gives out the same 5 cards for the chooosen players. I want it to give 5 random cards to the players. "card dealer"
rank = "" suit = "" import random r = random.randint(1,13) s = random.randint(1,4) if s == 1: suit = "spades" elif s == 2: suit = "heart" elif s == 3: suit = "diamond" elif s == 4: suit = "clubs" if r == 11: rank = "jack" elif r == 12: rank = "queen" elif r == 13: rank = "King" elif r > 1 and r < 11: rank = r i=int(input('how many players are gonna play poker?')) def poker (i): if i>0: print('player', +i, 'gets the cards') print(suit, rank) print(suit, rank) print(suit, rank) print(suit, rank) print(suit, rank) i-=1 r = random.randint(1,13) s = random.randint(1,4) print(poker(i)) print(poker(i))