Company: Meesho_6aug
Difficulty: medium
Book of the Year The table library holds information about various books: their id, title, rating and the year in which each book came out. Determine the highest-rated book of every year , in order of oldest to latest. Table: library Column Type Description id INTEGER Represents the book id (unique) title TEXT Represents the name of the book (two books may share a title) rating REAL Represents the rating of the book (out of 5) years INTEGER Represents the year in which the book came out Expected Output Return exactly these columns, in this order: Column Type Description id INTEGER The book id title TEXT The name of the book rating REAL The rating of the book years INTEGER The year in which the book came out Rules For every year that appears in the table, return the book(s) whose rating is the maximum rating among the books of that same year . If several books of the same year share that year's highest rating, return all of them. (inferred -- the original sample has one book per year an