while examples
This commit is contained in:
parent
faabeabea5
commit
2ab15cf61b
3 changed files with 15 additions and 0 deletions
4
while-1.py
Normal file
4
while-1.py
Normal file
|
@ -0,0 +1,4 @@
|
|||
i = 0
|
||||
while i < 10:
|
||||
print(i)
|
||||
i += 1
|
5
while-2.py
Normal file
5
while-2.py
Normal file
|
@ -0,0 +1,5 @@
|
|||
i = 0
|
||||
while i < 10:
|
||||
print(i, end = ' ')
|
||||
i += 1
|
||||
print()
|
6
while-3.py
Normal file
6
while-3.py
Normal file
|
@ -0,0 +1,6 @@
|
|||
i = 0
|
||||
while i < 0:
|
||||
print(i)
|
||||
i += 1
|
||||
else:
|
||||
print('son')
|
Loading…
Reference in a new issue