Lucy has forty-eight identical coins. She places half of them, with heads facing up, in a 4 by 6 rectangle. She uses the other twenty-four coins, with tails facing up, to form a frame around the rectangle. Mary has a different number of coins. She too, can use half of her coins to form a rectangle and the rest to precisely surround that rectangle with a frame. How many coins does Mary have ?
Let be the number of coins in the row and
be the number of coins in column. Thus there are
. Now this should be same as the number of coins in the frame
. We can write a small sagemath program to check
![](https://sumantmath.wordpress.com/wp-content/uploads/2022/12/screenshot-from-2022-12-14-23-37-23.png?w=393)
for x in range(1,1000):
for y in range(1,1000):
if (x*y==(2*x+2*y+4)):
print(x,y)
3 10
4 6
6 4
10 3
![](https://sumantmath.wordpress.com/wp-content/uploads/2022/12/screenshot-from-2022-12-14-23-37-45.png?w=568)
Thus there is just one more rectangle that exists and that rectangle is Quite amazing.