A light ray bends away from the normal when it travels from a denser medium to a rarer medium.
(1) Air to water: Air is rarer than water (less dense).
(2) Water to air: Water is denser than air (rarer).
(3) Water to glass: Water is less dense than glass (denser).
(4) Air to glass: Air is rarer than glass (denser).
The light ray bends away from the normal when it travels from water to air.