MCPcopy Create free account
hub / github.com/Mrinank-Bhowmick/python-beginner-projects / Deck

Class Deck

projects/Card Game/card.py:56–67  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

54
55
56class Deck:
57 def __init__(self):
58 self.cards = []
59 for i in range(2, 15):
60 for j in range(4):
61 self.cards.append(Card(i, j))
62 shuffle(self.cards)
63
64 def rm_card(self):
65 if len(self.cards) == 0:
66 return
67 return self.cards.pop()
68
69
70class Player:

Callers 1

__init__Method · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected