PhonePe interview question

Few programs to write based on data structure