Originally Posted by
Baloo
Evolution doesn’t have foresight. Earlier wings could have been used for rowing and skimming across the surface of water. Some insects still use wings primarily for this purpose today. Natural selection could then result in improved propulsion efficiency and techniques over time to a stage where some insects evolved to spontaneously hop off the surface of water - and these inherited advantageous traits resulted in descendants eventually adapting further to winged-based flight. So wings used for other purposes by ancestors eventually adapted for flight through opportunity and evolutionary advantage, not with flight in mind from the outset.