PY
py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
# Kallax (or formerly Expedit) shelves all are the same size. I wanted to calculate the sizes of the boxes I need to put in to maximize the use of the space. So I printed the arrangement of the boxes and underneath the size of each box in the arrangement.
def calc_expedit(h,w):
h = (33 / h)
w = (33 / w)
d = ("33 - 39cm")
print("h:" + str(h)+" w:"+str(w)+" d:"+"33.0")
print("[]\n")
calc_expedit(1,1)
print("\n[]\n[]\n")
calc_expedit(2,1)
calc_expedit(2,1)
print("\n [][]\n")
calc_expedit(1,2)
calc_expedit(1,2)
print("\n[][]\n[ ]\n")
calc_expedit(2,2)
calc_expedit(2,2)
calc_expedit(2,1)
print("\n[]\n[][]\n")
calc_expedit(2,2)
calc_expedit(2,2)
calc_expedit(1,2)
print("\n[] \n[] \n[]\n")
calc_expedit(3,1)
calc_expedit(3,1)
Enter to Rename, Shift+Enter to Preview
OUTPUT
Run