Discover interview question

using or without using window function to solve sql questions