Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class Storage:
- storage = []
- def __init__(self, capacity):
- self.capacity = capacity
- def add_product(self, product: str):
- if self.capacity > 0:
- Storage.storage.append(product)
- self.capacity -= 1
- def get_products(self):
- return Storage.storage
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement