From f0652b0dff8d7b5fc4f4f098bcbffe29cbf6a782 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elif=20=C3=96ZKANAT?= <154057945+elifozknt@users.noreply.github.com> Date: Sat, 3 Jan 2026 15:11:51 +0300 Subject: [PATCH 1/2] Add function to calculate pyramid height --- Week03/pyramid_first_last.py | 8 ++++++++ 1 file changed, 8 insertions(+) create mode 100644 Week03/pyramid_first_last.py diff --git a/Week03/pyramid_first_last.py b/Week03/pyramid_first_last.py new file mode 100644 index 00000000..97f3d839 --- /dev/null +++ b/Week03/pyramid_first_last.py @@ -0,0 +1,8 @@ +def calculate_pyramid_height(number_of_blocks): + height=0 + while number_of_blocks >= (height+1): + height+=1 + number_of_blocks-=height + return height + +print(calculate_pyramid_height(240)) From cb7b43a53867bdf6e709afc5a32d013bb767592d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Elif=20=C3=96ZKANAT?= <154057945+elifozknt@users.noreply.github.com> Date: Sat, 3 Jan 2026 15:32:10 +0300 Subject: [PATCH 2/2] Rename pyramid_first_last.py to pyramid_elif_ozkanat.py --- Week03/{pyramid_first_last.py => pyramid_elif_ozkanat.py} | 0 1 file changed, 0 insertions(+), 0 deletions(-) rename Week03/{pyramid_first_last.py => pyramid_elif_ozkanat.py} (100%) diff --git a/Week03/pyramid_first_last.py b/Week03/pyramid_elif_ozkanat.py similarity index 100% rename from Week03/pyramid_first_last.py rename to Week03/pyramid_elif_ozkanat.py