We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 71f5b39 commit 963719fCopy full SHA for 963719f
Week03/pyramid_gamze_kilinc.py
@@ -0,0 +1,9 @@
1
+def calculate_pyramid_height(number_of_blocks):
2
+ height = 0
3
+ used_blocks = 0
4
+
5
+ while used_blocks + (height + 1) <= number_of_blocks:
6
+ height += 1
7
+ used_blocks += height
8
9
+ return height
0 commit comments