python the hard way ex.
This commit is contained in:
parent
7b39b906fb
commit
dab9fe5912
9 changed files with 133 additions and 0 deletions
26
sami/learn-python-the-hard-way/ex6.py
Normal file
26
sami/learn-python-the-hard-way/ex6.py
Normal file
|
|
@ -0,0 +1,26 @@
|
|||
types_of_people = 10
|
||||
x = f"There are {types_of_people} types of people."
|
||||
|
||||
binary = "binary"
|
||||
do_not = "don't"
|
||||
y = f"Those who know {binary} and those who {do_not}."
|
||||
|
||||
print(x)
|
||||
print(y)
|
||||
|
||||
print(f"I said: {x}")
|
||||
print(f"I also said: '{y}'")
|
||||
|
||||
|
||||
hilarious = False
|
||||
|
||||
|
||||
joke_evaluation = "Isn't that joke so funny?! {}"
|
||||
|
||||
|
||||
print(joke_evaluation.format(hilarious))
|
||||
|
||||
w = "This is the left side of..."
|
||||
e = "a string with a right side."
|
||||
|
||||
print(w + e)
|
||||
Loading…
Add table
Add a link
Reference in a new issue