First Code
#this is my first code
print("Hello, this is my first code")
#maths practice
print("I will count my pets")
print("Dogs",2*3/2)
print("Hamsters",10/2)
print("Rabbits",5+7)
print("All together, I have",3+5+12,"pets")
print(20,"pets are a lot to handle")
#greater than or equal to
print("Do I have more hamsters than dogs?",3<=5)
print("Do I have more rabbits than hamsters?",12>=5)
print("Do I have more dogs than rabbits?",3>12)
print("Do I have an equal or greater number of rabbits than dogs?",12>=3)
print("Do I have an equal number of hamsters to dogs?",3==5)
#drawing a pattern
Hello, this is my first code
I will count my pets
Dogs 3.0
Hamsters 5.0
Rabbits 12
All together, I have 20 pets
20 pets are a lot to handle
Do I have more hamsters than dogs? True
Do I have more rabbits than hamsters? True
Do I have more dogs than rabbits? False
Do I have an equal or greater number of rabbits than dogs? True
Do I have an equal number of hamsters to dogs? False
Programming Progress Log
More posts
- List FunctionsNov 14, 2022
- Python Classes/ObjectsOct 24, 2022
- While LoopsOct 24, 2022
- LoopsOct 16, 2022
- ListsOct 16, 2022
- Short Circuit PracticeOct 16, 2022
- Using VariablesOct 15, 2022
- Converting degrees to farenheitOct 15, 2022