commit 8ba9aeb3cea847b63a91ac378a2a6db758682460 Author: smartiqa Date: Thu Mar 4 14:54:08 2021 +0300 L-03: Circle and square added diff --git a/circle.py b/circle.py new file mode 100644 index 0000000..c3eb864 --- /dev/null +++ b/circle.py @@ -0,0 +1,10 @@ +import math + + +def area(r): + return math.pi * r * r + + +def perimeter(r): + return 2 * math.pi * r + diff --git a/square.py b/square.py new file mode 100644 index 0000000..0f98724 --- /dev/null +++ b/square.py @@ -0,0 +1,7 @@ + +def area(a): + return a * a + + +def perimeter(a): + return 4 * a