Think of the slant height (s) and vertical height (v) as being 2 sides of a right angle triangle. The slant height is the hypotenuse. The third side is the distance from the center of the base to the middle of one side of the base. Since the base is a square, this third side is actually half the side length (x) the question is asking us for.
You can relate these using the Pythagorean Theorem: