mirror of
https://github.com/szymon-jozef/ZUT-notatki.git
synced 2026-10-28 11:10:38 +01:00
bla
This commit is contained in:
11
uczelnia/2_semestr/python/laby/9/zad3.py
Normal file
11
uczelnia/2_semestr/python/laby/9/zad3.py
Normal file
@@ -0,0 +1,11 @@
|
||||
from typing import Generator
|
||||
|
||||
|
||||
def power_of_number(number: int, min_exp: int = 0, max_exp: int = 10) -> Generator[int]:
|
||||
for i in range(min_exp, max_exp):
|
||||
yield number**i
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
for i in power_of_number(4):
|
||||
print(i)
|
||||
Reference in New Issue
Block a user