Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
  • Loading branch information
snow feng committed Feb 12, 2024
2 parents 655bbc3 + 927634e commit cb72139
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 0 deletions.
10 changes: 10 additions & 0 deletions CartonPython/lesson5/ch5_2_1_2_fcpp.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# coding=utf-8
# Filename: ch5_2_1_2_fcpp.py

i = 0

while i * i < 901:
i += 1
print(str(i) + '*' + str(i) + ' =', i * i)
else:
print('While over!')
10 changes: 10 additions & 0 deletions CartonPython/lesson5/ch5_2_1_fcpp.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
# coding=utf-8
# Filename: ch5_2_1_fcpp.py

i = 10

while i * i > 50:
i -= 1

print("i = " + str(i))
print("i * i = " + str(i * i))

0 comments on commit cb72139

Please sign in to comment.