annotate bubblesort/test.py @ 14:4770f6dca839

bing4desktop-0.240206-3.1
author prymula <prymula76@outlook.com>
date Tue, 06 Feb 2024 18:07:17 +0100
parents dcd610585610
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
0
prymula <prymula76@outlook.com>
parents:
diff changeset
1 #!/usr/bin/env python3
prymula <prymula76@outlook.com>
parents:
diff changeset
2
prymula <prymula76@outlook.com>
parents:
diff changeset
3 """
prymula <prymula76@outlook.com>
parents:
diff changeset
4 for i int range(0,5):
prymula <prymula76@outlook.com>
parents:
diff changeset
5 print (i)
prymula <prymula76@outlook.com>
parents:
diff changeset
6 """
prymula <prymula76@outlook.com>
parents:
diff changeset
7
prymula <prymula76@outlook.com>
parents:
diff changeset
8 def func(i):
prymula <prymula76@outlook.com>
parents:
diff changeset
9 if i == 0:
prymula <prymula76@outlook.com>
parents:
diff changeset
10 return
prymula <prymula76@outlook.com>
parents:
diff changeset
11 print(i)
prymula <prymula76@outlook.com>
parents:
diff changeset
12 func(i-1)
prymula <prymula76@outlook.com>
parents:
diff changeset
13
prymula <prymula76@outlook.com>
parents:
diff changeset
14 func(5)
prymula <prymula76@outlook.com>
parents:
diff changeset
15