The gas giants are primarily made up of hydrogen and helium. In contrast, the inner terrestrial planets have mostly rocky surfaces. The differences between these inner and outer planets are the result of the Sun’s radiant energy.