diff --git a/Project 1/Card.py b/Project 1/Card.py index 3052a85..307c5af 100644 --- a/Project 1/Card.py +++ b/Project 1/Card.py @@ -19,13 +19,4 @@ class Card: def __repr__(self) -> str: return f"{self._value} of {self._suit}" - #Returns a string representation of the card in the format "Value of Suit". - - def __add__(self, other) -> int: - #Adding 2 cards together - if isinstance(other, Card): - return self.value + other.value - elif isinstance(other, int): - #allows adding a card to an int - return self.value + other - #Added for project 2: Created an "__add__" meathod to allow adding Cards together. + #Returns a string representation of the card in the format "Value of Suit". \ No newline at end of file diff --git a/Project 1/Deck.py b/Project 1/Deck.py index 21f8a1b..df0c047 100644 --- a/Project 1/Deck.py +++ b/Project 1/Deck.py @@ -1,5 +1,6 @@ import random from Card import Card + """ Defines the deck of cards used in the Solitaire game. Contains methods to shuffle the deck, deal cards, and check the number of remaining cards.