-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathex7.py
More file actions
39 lines (37 loc) · 1.26 KB
/
ex7.py
File metadata and controls
39 lines (37 loc) · 1.26 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
# Print string to standard screen output
print("Mary had a little lamb.")
# Print string to standard screen output and format the {} with the word 'snow'
print("It's fleece was white as {}.".format('snow'))
# Print string to standard screen output
print("And everywhere that Mary went.")
# Print string to standard screen output ten times in a row
print("." * 10) # what did that do?
# Assign variable 'end1' eqaul to 'C'
end1 = "C"
# Assign variable 'end2' eqaul to 'h'
end2 = "h"
# Assign variable 'end3' eqaul to 'e'
end3 = "e"
# Assign variable 'end4' eqaul to 'e'
end4 = "e"
# Assign variable 'end5' eqaul to 's'
end5 = "s"
# Assign variable 'end6' eqaul to 'e'
end6 = "e"
# Assign variable 'end7' eqaul to 'B'
end7 = "B"
# Assign variable 'end8' eqaul to 'u'
end8 = "u"
# Assign variable 'end9' eqaul to 'r'
end9 = "r"
# Assign variable 'end10' eqaul to 'g'
end10 = "g"
# Assign variable 'end11' eqaul to 'e'
end11 = "e"
# Assign variable 'end12' eqaul to 'r'
end12 = "r"
# Print the 'end#' variables to standard screen output joining them together
# for a single line string adding a space between the lines.
# watch that comma at the end. try removing it to see what happens
print(end1 + end2 + end3 + end4 + end5 + end6, end=' ')
print(end7 + end8 + end9 + end10 + end11 + end12)