Hello, perash!

I used the same approach as ticbol, but got a different answer.

Consider a pyramid with a square base. The side length of the base is 2 units

and the height of the pyramid is 1 unit. Imagine placing a cube inside this pyramid

(resting on the base of the pyramid) so that each of the four top corners of the cube

is touching each of the 4 slanted edges of the pyramid.

Find the dimensions of the cube.

That is, find the value, in units, of the length of one edge of the cube. Looking down on the pyramid, we see: Code:

*-----------*
| * * |
| * * |
| * | 2
| * * |
| * * |
*-----------*
2

The diagonal of this square is

Slice the pyramid along a diagonal and we have this cross-section: Code:

- *
: * | *
: * | *
: *-----+-----*
1 * | | | *
: * | | | *
: * | | 2x| *
: * | | | *
- *---------*-----*-----*---------*
: √2 : x : √2-x :

The lower-right right triangle is similar to the largest right triangle.

We have: .

. .

The side of the cube is: .