0% found this document useful (0 votes)
2 views37 pages

Projektmappe Python

Uploaded by

veronikabojko543
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
2 views37 pages

Projektmappe Python

Uploaded by

veronikabojko543
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOCX, PDF, TXT or read online on Scribd

Projekt Mappe: Life-Simulator

Elena Kämpgen 9d; Veronika Boiko 9c


Von 08.12.2025 bis 16.01.2026
Daltongymnasium der Stadt Alsdorf
2025-2026
Abgabedatum: 16.01.2026 13:15
Inhaltsverzeichnis:
 Ziele
 Plan
 Tagesprotokolle
 Korrekturen/Problemen
 Python-Projekt
 Selbsteinschätzung
 Quellenangaben
Ziele:
Code verbessern:
Input hinzufügen
Mehr Variablen z.B. health, hunger, thirst
1 mal am Tag wählen
Backstory hinzufügen
Plan:
Kein Plan
11.12.2025. [Link]: Zusammen
from random import *

class Life:

def init(self, name): [Link] = name

#Happy
[Link] = 50

#progress
[Link] = 100

#Alien
[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

def to_work(self): print("Time to work! :((((") [Link] += 50 [Link] -= 3

def to_sleep(self): print("I will sleep.") [Link] += 3 def to_chill(self): print("rest time") [Link] += 5 [Link] -= 0.1

def is_alive(self): if [Link] < 50: print("You are broke.") [Link] = False

if [Link] < 0:
print("You are a suicide lover. ;)")
[Link] = False

def end_of_day(self): print(f"Gladness = {[Link]}") print(f"Progress = {[Link]}") print()

def live(self, day): print(f"Day - {day} of {[Link]}")

live_cube = randint(1,3)

if live_cube == 1:
self.to_work()

elif live_cube == 2:
self.to_chill()

elif live_cube == 3:
self.to_sleep()

self.end_of_day()

self.is_alive()

Max = Life("Max") for day in range(25550): if day == 25549: print ("You had a great life! Thank you for passing Max' life)") if [Link] == False: break

[Link](day)

12.12.2025 [Link]: Zusammen


from random import * class Life:

def init(self, name): [Link] = name

#Happy
[Link] = 50

#progress
[Link] = 100
#Alien
[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

def to_work(self): print("Time to work! :((((") [Link] += 50 [Link] -= 3 [Link] -= 40 [Link] -= 30 [Link] -= 5

def to_sleep(self): print("Max will sleep.") [Link] += 3 [Link] += 5 [Link] -= 5 def to_chill(self): print("rest time") [Link] += 5 [Link] -= 10

def to_doctor(self): print("Max is going to the doctor.") [Link] += 40 [Link] -= 40

def to_eat(self): print('Max ate!') [Link] += 50 [Link] += 10 [Link] -= 15 [Link] += 5

def to_drink(self): print('Max drank!') [Link] += 40 [Link] -= 5 [Link] += 5

def to_goThroughtTrash(self): print("Max looked for food.") [Link] += 30 [Link] += 10 [Link] -= 30

def is_alive(self): if [Link] < 50: print("Max is broke.") [Link] = False

if [Link] < 0:
print("Max is a suicide lover. ;)")
[Link] = False

if [Link] <= 0:
print("Max died from sickness:(")
[Link] = False

if [Link] <= 0:
print("Max died from hunger:(")
[Link] = False

if [Link] <= 0:
print("Max died from thirst:(")
[Link] = False

def end_of_day(self): print(f"Gladness = {[Link]}") print(f"Money = {[Link]}") print(f"Hunger = {[Link]}") print(f"Thirst = {[Link]}") print(f"Health = {[Link]}")
print()

def live(self, day): print(f"Day - {day} of {[Link]}")

live_cube = randint(1,7)

if live_cube == 1:
self.to_work()

elif live_cube == 2:
self.to_chill()

elif live_cube == 3:
self.to_sleep()

elif live_cube == 4:
self.to_doctor()

elif live_cube == 5:
self.to_drink()

elif live_cube == 6:
self.to_eat()

elif live_cube == 7:
self.to_goThroughtTrash()

self.end_of_day()

self.is_alive()
print('Max Carter is 20 years old, living in a cramped studio apartment on the rougher side of the city. He grew up in a quiet suburban neighborhood, but life fell apart fast after high
school. His parents divorced, money got tight, and Max decided to move out early to avoid being a burden. He thought independence would feel freeing—but instead, it felt like a slow
dive into chaos He works part-time jobs whenever he can find them—stocking shelves at night, delivering food on an old bike, or helping out at a local garage. But no matter how hard he
tries, the bills stack up faster than his paychecks. His fridge is often empty, his phone bill is always overdue, and his dreams keep getting pushed aside “until next month.” Will you help
him to live?') first_decision = int(input('yes or no? 1 = yes; no = 2: ')) if first_decision == 2: print('Look what you did: ') Max = Life("Max") for day in range(25550): if day == 25549: print
("Max had a great life! Thank you for passing Max' life)") if [Link] == False: break

[Link](day)

if first_decision == 1:

15.12.2025 3. Stunde Elena

from random import *

class Life:
def __init__(self, name):

[Link] = name

#Happy

[Link] = 50

#progress

[Link] = 100

#Alien

[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

def to_work(self):

print("Time to work! :((((")

[Link] += 50

[Link] -= 3

[Link] -= 40

[Link] -= 30

[Link] -= 5

def to_sleep(self):

print("Max will sleep.")

[Link] += 3

[Link] += 5

[Link] -= 5

def to_chill(self):

print("rest time")

[Link] += 5

[Link] -= 10

def to_doctor(self):

print("Max is going to the doctor.")

[Link] += 40

[Link] -= 40

def to_eat(self):

print('Max ate!')

[Link] += 50

[Link] += 10
[Link] -= 15

[Link] += 5

def to_drink(self):

print('Max drank!')

[Link] += 40

[Link] -= 5

[Link] += 5

def to_goThroughtTrash(self):

print("Max looked for food.")

[Link] += 30

[Link] += 10

[Link] -= 30

def is_alive(self):

if [Link] < 50:

print("Max is broke.")

[Link] = False

if [Link] < 0:

print("Max is a suicide lover. ;)")

[Link] = False

if [Link] <= 0:

print("Max died from sickness:(")

[Link] = False

if [Link] <= 0:

print("Max died from hunger:(")

[Link] = False

if [Link] <= 0:

print("Max died from thirst:(")

[Link] = False

def end_of_day(self):

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()
def live(self, day):

print(f"Day - {day} of {[Link]}")

live_cube = randint(1,7)

if live_cube == 1:

self.to_work()

elif live_cube == 2:

self.to_chill()

elif live_cube == 3:

self.to_sleep()

elif live_cube == 4:

self.to_doctor()

elif live_cube == 5:

self.to_drink()

elif live_cube == 6:

self.to_eat()

elif live_cube == 7:

self.to_goThroughtTrash()

self.end_of_day()

self.is_alive()

class LifeyourChoice:

def __init__(self, name):

[Link] = name

#Happy

[Link] = 50

#progress

[Link] = 100

#Alien

[Link] = True

[Link] = 100
[Link] = 100

[Link] = 100

def to_work(self):

print("Time to work! :((((")

[Link] += 50

[Link] -= 3

[Link] -= 40

[Link] -= 30

[Link] -= 5

def to_sleep(self):

print("Max will sleep.")

[Link] += 3

[Link] += 5

[Link] -= 5

def to_chill(self):

print("rest time")

[Link] += 5

[Link] -= 10

def to_doctor(self):

print("Max is going to the doctor.")

[Link] += 40

[Link] -= 40

def to_eat(self):

print('Max ate!')

[Link] += 50

[Link] += 10

[Link] -= 15

[Link] += 5

def to_drink(self):

print('Max drank!')

[Link] += 40

[Link] -= 5

[Link] += 5

def to_goThroughtTrash(self):

print("Max looked for food.")

[Link] += 30

[Link] += 10
[Link] -= 30

def is_alive(self):

if [Link] < 50:

print("Max is broke.")

[Link] = False

if [Link] < 0:

print("Max is a suicide lover. ;)")

[Link] = False

if [Link] <= 0:

print("Max died from sickness:(")

[Link] = False

if [Link] <= 0:

print("Max died from hunger:(")

[Link] = False

if [Link] <= 0:

print("Max died from thirst:(")

[Link] = False

def end_of_day(self):

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

def live(self, day):

print(f"Day - {day} of {[Link]}")

for day in range(25550).

int(input('What do you want to do? 1 = Work and earn money; 2 = sleep;'))

print('Max Carter is 20 years old, living in a cramped studio apartment on the rougher side of the city. He grew up in a quiet suburban neighborhood, but life fell apart fast after high
school. His parents divorced, money got tight, and Max decided to move out early to avoid being a burden. He thought independence would feel freeing—but instead, it felt like a slow
dive into chaos. He works part-time jobs whenever he can find them — stocking shelves at night, delivering food on an old bike, or helping out at a local garage. But no matter how hard
he tries, the bills stack up faster than his paychecks. His fridge is often empty, his phone bill is always overdue, and his dreams keep getting pushed aside “until next month.” Will
you help him to live?')

first_decision = int(input('yes or no? 1 = yes; no = 2: '))

if first_decision == 2:

print('Look what you did: ')

Max = Life("Max")
for day in range(25550):

if day == 25549:

print ("Max had a great life! Thank you for passing Max' life)")

if [Link] == False:

break

[Link](day)

if first_decision == 1:

Max = LifeyourChoice("Max")

for day in range(25550):

if day == 25549:

print ("Max had a great life! Thank you for passing Max' life)")

if [Link] == False:

break

[Link](day)
19.12.2025 2. Stunde Elena
from random import * class Life:

def init(self, name): [Link] = name

#Happy
[Link] = 50

#progress
[Link] = 100

#Alien
[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

def to_work(self): print("Time to work! :((((") [Link] += 50 [Link] -= 3 [Link] -= 40 [Link] -= 30 [Link] -= 5

def to_sleep(self): print("Max will sleep.") [Link] += 3 [Link] += 5 [Link] -= 5 def to_chill(self): print("rest time") [Link] += 5 [Link] -= 10

def to_doctor(self): print("Max is going to the doctor.") [Link] += 40 [Link] -= 40

def to_eat(self): print('Max ate!') [Link] += 50 [Link] += 10 [Link] -= 15 [Link] += 5

def to_drink(self): print('Max drank!') [Link] += 40 [Link] -= 5 [Link] += 5

def to_goThroughtTrash(self): print("Max looked for food.") [Link] += 30 [Link] += 10 [Link] -= 30

def is_alive(self): if [Link] < 50: print("Max is broke.") [Link] = False

if [Link] < 0:
print("Max is a suicide lover. ;)")
[Link] = False

if [Link] <= 0:
print("Max died from sickness:(")
[Link] = False

if [Link] <= 0:
print("Max died from hunger:(")
[Link] = False

if [Link] <= 0:
print("Max died from thirst:(")
[Link] = False

def end_of_day(self): print(f"Gladness = {[Link]}") print(f"Money = {[Link]}") print(f"Hunger = {[Link]}") print(f"Thirst = {[Link]}") print(f"Health = {[Link]}")
print()
def live(self, day): print(f"Day - {day} of {[Link]}")

live_cube = randint(1,7)

if live_cube == 1:
self.to_work()

elif live_cube == 2:
self.to_chill()

elif live_cube == 3:
self.to_sleep()

elif live_cube == 4:
self.to_doctor()

elif live_cube == 5:
self.to_drink()

elif live_cube == 6:
self.to_eat()

elif live_cube == 7:
self.to_goThroughtTrash()

self.end_of_day()

self.is_alive()

class LifeyourChoice:

def init(self, name): [Link] = name

#Happy
[Link] = 50

#progress
[Link] = 100

#Alien
[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

def to_work(self): print("Time to work! :((((") [Link] += 50 [Link] -= 3 [Link] -= 40 [Link] -= 30 [Link] -= 5

def to_sleep(self): print("Max will sleep.") [Link] += 3 [Link] += 5 [Link] -= 5

def to_chill(self): print("rest time") [Link] += 5 [Link] -= 10

def to_doctor(self): print("Max is going to the doctor.") [Link] += 40 [Link] -= 40

def to_eat(self): print('Max ate!') [Link] += 50 [Link] += 10 [Link] -= 15 [Link] += 5

def to_drink(self): print('Max drank!') [Link] += 40 [Link] -= 5 [Link] += 5

def to_goThroughtTrash(self): print("Max looked for food.") [Link] += 30 [Link] += 10 [Link] -= 30

def is_alive(self): if [Link] < 50: print("Max is broke.") [Link] = False

if [Link] < 0:
print("Max is a suicide lover. ;)")
[Link] = False

if [Link] <= 0:
print("Max died from sickness:(")
[Link] = False
if [Link] <= 0:
print("Max died from hunger:(")
[Link] = False

if [Link] <= 0:
print("Max died from thirst:(")
[Link] = False

def end_of_day(self): print(f"Gladness = {[Link]}") print(f"Money = {[Link]}") print(f"Hunger = {[Link]}") print(f"Thirst = {[Link]}") print(f"Health = {[Link]}")
print()

def live(self, day): print(f"Day - {day} of {[Link]}")

YourChoice = int(input('What do you want to do? 1 = work and earn money; 2 = sleep; 3 = chill; 4 = going to the doctor; 5 =
eat; 6 = drink; 7 = going through trash cans: '))
if YourChoice == 1:
self.to_work()

elif YourChoice == 2:
self.to_sleep()

elif YourChoice == 3:
self.to_chill()

elif YourChoice == 4:
self.to_doctor()

elif YourChoice == 5:
self.to_eat()

elif YourChoice == 6:
self.to_drink()

elif YourChoice == 7:
self.to_goThroughtTrash()

print('Max Carter is 20 years old, living in a cramped studio apartment on the rougher side of the city. He grew up in a quiet suburban neighborhood, but life fell apart fast after high
school. His parents divorced, money got tight, and Max decided to move out early to avoid being a burden. He thought independence would feel freeing—but instead, it felt like a slow
dive into chaos. He works part-time jobs whenever he can find them — stocking shelves at night, delivering food on an old bike, or helping out at a local garage. But no matter how hard
he tries, the bills stack up faster than his paychecks. His fridge is often empty, his phone bill is always overdue, and his dreams keep getting pushed aside “until next month.” Will you help
him to live?') first_decision = int(input('yes or no? 1 = yes; no = 2: ')) if first_decision == 2: print('Look what you did: ') Max = Life("Max") for day in range(25550): if day == 25549: print
("Max had a great life! Thank you for passing Max' life)") if [Link] == False: break

[Link](day)

if first_decision == 1: Max = LifeyourChoice("Max") for day in range(25550): if day == 25549: print ("Max had a great life! Thank you for passing Max' life)") if [Link] == False: break

[Link](day)
09.01.2026 2. Stunde Veronika&Elena
from random import * #bibliothek

class Life:

#computer entscheidet

def __init__(self, name):#stats

[Link] = name

#Happy

[Link] = 50

#progress

[Link] = 100
#Alien

[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

#sachen für machen

def to_work(self):

print("Time to work! :((((")

[Link] += 50

[Link] -= 3

[Link] -= 40

[Link] -= 30

[Link] -= 5

def to_sleep(self):

print("Max will sleep.")

[Link] += 3

[Link] += 5

[Link] -= 5

def to_chill(self):

print("rest time")

[Link] += 5

[Link] -= 10

def to_doctor(self):

print("Max is going to the doctor.")

[Link] += 40

[Link] -= 40

def to_eat(self):

print('Max ate!')

[Link] += 50

[Link] += 10

[Link] -= 15
[Link] += 5

def to_drink(self):

print('Max drank!')

[Link] += 40

[Link] -= 5

[Link] += 5

def to_goThroughtTrash(self):

print("Max looked for food.")

[Link] += 30

[Link] += 10

[Link] -= 30

#sachen für sterben

def is_alive(self):

if [Link] < 50:

print("Max is broke.")

[Link] = False

if [Link] < 0:

print("Max is a suicide lover. ;)")

[Link] = False

if [Link] <= 0:

print("Max died from sickness:(")

[Link] = False

if [Link] <= 0:

print("Max died from hunger:(")

[Link] = False

if [Link] <= 0:

print("Max died from thirst:(")

[Link] = False

#stats ausgeben

def end_of_day(self):

print(f"Gladness = {[Link]}")
print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

#random von bibliothek da oben

def live(self, day):

print(f"Day - {day} of {[Link]}")

live_cube = randint(1,7)

if live_cube == 1:

self.to_work()

elif live_cube == 2:

self.to_chill()

elif live_cube == 3:

self.to_sleep()

elif live_cube == 4:

self.to_doctor()

elif live_cube == 5:

self.to_drink()

elif live_cube == 6:

self.to_eat()

elif live_cube == 7:

self.to_goThroughtTrash()

self.end_of_day()

self.is_alive()#gucken ob es noch lebt

class LifeyourChoice:

#FÜR selber entscheiden


def __init__(self, name):

[Link] = name

#Happy

[Link] = 50

#progress

[Link] = 100

#Alien

[Link] = True

[Link] = 100

[Link] = 100

[Link] = 100

def to_work(self):

print("Time to work! :((((")

[Link] += 50

[Link] -= 3

[Link] -= 40

[Link] -= 30

[Link] -= 5

def to_sleep(self):

print("Max will sleep.")

[Link] += 3

[Link] += 5

[Link] -= 5

def to_chill(self):

print("rest time")

[Link] += 5

[Link] -= 10

def to_doctor(self):
print("Max is going to the doctor.")

[Link] += 40

[Link] -= 40

def to_eat(self):

print('Max ate!')

[Link] += 50

[Link] += 10

[Link] -= 15

[Link] += 5

def to_drink(self):

print('Max drank!')

[Link] += 40

[Link] -= 5

[Link] += 5

def to_goThroughtTrash(self):

print("Max looked for food.")

[Link] += 30

[Link] += 10

[Link] -= 30

def is_alive(self):

if [Link] < 50:

print("Max is broke.")

[Link] = False

if [Link] < 0:

print("Max is a suicide lover. ;)")

[Link] = False

if [Link] <= 0:

print("Max died from sickness:(")

[Link] = False

if [Link] <= 0:

print("Max died from hunger:(")


[Link] = False

if [Link] <= 0:

print("Max died from thirst:(")

[Link] = False

#für selber entscheiden

def live(self, day):

print(f"Day - {day} of {[Link]}")

YourChoice = int(input('What do you want to do? 1 = work and earn money; 2 = sleep; 3 = chill; 4 = going to the doctor; 5 = eat; 6 = drink;
7 = going through trash cans: '))

if YourChoice == 1:

self.to_work()

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

elif YourChoice == 2:

self.to_sleep()

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

elif YourChoice == 3:

self.to_chill()

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

elif YourChoice == 4:

self.to_doctor()
print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

elif YourChoice == 5:

self.to_eat()

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

elif YourChoice == 6:

self.to_drink()

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

elif YourChoice == 7:

self.to_goThroughtTrash()

print(f"Gladness = {[Link]}")

print(f"Money = {[Link]}")

print(f"Hunger = {[Link]}")

print(f"Thirst = {[Link]}")

print(f"Health = {[Link]}")

print()

self.is_alive()

#entscheiden ob man spielen will

print('Max Carter is 20 years old, living in a cramped studio apartment on the rougher side of the city. He grew up in a quiet suburban
neighborhood, but life fell apart fast after high school. His parents divorced, money got tight, and Max decided to move out early to avoid
being a burden. He thought independence would feel freeing—but instead, it felt like a slow dive into chaos. He works part-time jobs
whenever he can find them — stocking shelves at night, delivering food on an old bike, or helping out at a local garage. But no matter how
hard he tries, the bills stack up faster than his paychecks. His fridge is often empty, his phone bill is always overdue, and his dreams keep
getting pushed aside “until next month.” Will you help him to live?')

first_decision = int(input('yes or no? 1 = yes; no = 2: '))


if first_decision == 2:

print('Look what you did: ')

Max = Life("Max")

for day in range(25550):

if day == 25549:

print ("Max had a great life! Thank you for passing Max' life)")

if [Link] == False:

break

[Link](day)

if first_decision == 1:

Max = LifeyourChoice("Max")

for day in range(25550):

if day == 25549:

print ("Max had a great life! Thank you for passing Max' life)")

if [Link] == False:

break

[Link](day)
Quellen:
Ausgangscode:
from random import *

class Student:

def init(self, name): [Link] = name

#Happy
[Link] = 50

#progress
[Link] = 0
#Alien
[Link] = True

def to_study(self): print("Time to study! :((((") [Link] += 0.12 [Link] -= 3

def to_sleep(self): print("I will sleep.") [Link] += 3 def to_chill(self): print("rest time") [Link] += 5 [Link] -= 0.1

def is_alive(self): if [Link] < -0.5: print("You are a corp.") [Link] = False

if [Link] < 0:
print("You are a suicide lover. ;)")
[Link] = False

if [Link] > 5:
print("Guy, you are cool. You are not as dumb as I thought.")
[Link] = False

def end_of_day(self): print(f"Gladness = {[Link]}") print(f"Progress = {[Link]}") print()

def live(self, day): print(f"Day - {day} of {[Link]}")

live_cube = randint(1,3)

if live_cube == 1:
self.to_study()

elif live_cube == 2:
self.to_chill()

elif live_cube == 3:
self.to_sleep()

self.end_of_day()

self.is_alive()

Max = Student("name")

for day in range(365):

if day == 364:

print ("You survived!")

if [Link] == False:

break

[Link](day)

Max Carter is 20 years old, living in a cramped studio apartment on the rougher side of the city. He
grew up in a quiet suburban neighborhood, but life fell apart fast after high school. His parents
divorced, money got tight, and Max decided to move out early to avoid being a burden. He thought
independence would feel freeing—but instead, it felt like a slow dive into chaos He works part-time
jobs whenever he can find them—stocking shelves at night, delivering food on an old bike, or helping
out at a local garage. But no matter how hard he tries, the bills stack up faster than his paychecks. His
fridge is often empty, his phone bill is always overdue, and his dreams keep getting pushed aside
“until next month.”

You might also like