Consider two waves traveling through the same medium in the same time frame

Consider two waves X and Y traveling in the same medium. The two carry the same amount of energy per unit time, but X has half the amplitude of Y.

a. What is the ratio of their wavelengths?
b. Which wave has the longer wavelength?