diff --git a/dzien_05/klasy_03_tl.py b/dzien_05/klasy_03_tl.py index 2bd9d6b..3a00838 100644 --- a/dzien_05/klasy_03_tl.py +++ b/dzien_05/klasy_03_tl.py @@ -1,10 +1,10 @@ class Computer: - def __init__(self, info: str, typ: str): + def __init__(self, info: str, typ: str, speed: int): print("Startujemy...") # definicja właściwości obiektów tej lasy self.procesor = "CPU at start" self.speed = "5 GHz" - self.cpu_speed = 5000 + self.cpu_speed = speed self.informacja = info self.typ = typ @@ -23,7 +23,7 @@ class Computer: # missing 1 required positional argument: # 'info' komputer1 = Computer("Komputer z lat 90tych", "XT", 1200) -komputer2 = Computer("Inna informacja", "AT") +komputer2 = Computer("Inna informacja", "AT", 4000) print(komputer1) print('-------------------')