STMicroelectronics Interview Question

Some queries to write specifically group by ?