learning Python 3 diary#3
Dear Diary,
I've caught a cold couple of days ago and it has progressed and bloomed into a light fever. Being unable to think properly I have resigned to reading and mostly sleeping.
I feel a lot better so have restarted on my learning to code journey ^^
Today on the menu are Conditionals :D
Finally!!!
sick = input("Are you sick? ")
if sick.startswith("y"):
print("Go home and rest!")
else:
pass
if sick.startswith("n"):
print("Get ready for some Pizza!")
else:
print("let's do Pizza next time")
It feels like learning ABC at the moment :D
Especially since it's easy to find loopholes 🤔
Like in this exercise, if I enter two words instead of one the second part isn't executed.
I suppose space somehow interferes with the second part and there are more things needed to make it run even if i enter "lol lol lol" :D
~Anmitsu
Leave learning Python 3 diary#3 to:
Read more #learning posts
Best Posts From anmitsu
We have not curated any of anmitsu's posts yet. But you can encourage our curation team to review posts by visiting them regularly and by referring other readers. Because we give priority to frequently read content.
More Posts From anmitsu
- The loops of spring.
- Make your feed filled with pancakes again! Join in the pancake battle.
- Python Practice
- Git, sudo and alias adventures on an updated macOS Sierra.
- Return...return... python diary #4
- Intro post - I like spaghetti 🍝
- Building bridges across eternity, borrowing books at Openlibrary.org
- testing the code insert
- test post 2 with images
- learning Python 3 diary#3
- Learning to code in Python 3 diary #2
- Learning to code in Python 3 - diary #1