push
This commit is contained in:
@@ -0,0 +1,18 @@
|
||||
class Plant:
|
||||
def __init__(self, name, heigt, age):
|
||||
self.name = name
|
||||
self.heigt = heigt
|
||||
self.age = age
|
||||
|
||||
|
||||
def ft_garden_data():
|
||||
rose = Plant("Rose: ", 25, 30)
|
||||
Sunflower = Plant("Sunflower: ", 80, 45)
|
||||
Cactus = Plant("Cactus: ", 15, 120)
|
||||
print("=== Garden Plant Registry ===")
|
||||
print(rose.name, rose.heigt, "cm,", rose.age, "days old")
|
||||
print(Sunflower.name, Sunflower.heigt, "cm,", Sunflower.age, "days old")
|
||||
print(Cactus.name, Cactus.heigt, "cm,", Cactus.age, "days old")
|
||||
|
||||
|
||||
ft_garden_data()
|
||||
Reference in New Issue
Block a user