In the given case, most probably the top layer is of oil.
As oil is not soluble in water, it will float on the top of the water surface, in the given case it is the beaker. The oil will always float on top of the water, as it is less dense in comparison to water. The water and oil do not mix as the molecules of water are more fascinated with each other than in comparison to the molecules of oil.
As water is polar and oil is nonpolar, their molecules are not attracted to each other.