Assignment2
Assignment2 Add a new field to Book and BookRequest called published_date: int (for example, published_date: int = 2012). So,this book as published on the year of 2012. Enhance each Book to now have a published_date Then create a new GET request method to filter by published_date Code: from fastapi import FastAPI , Body from books3 import Book from datavalidatorhelper import BookRequest app = FastAPI () BOOKS = [ Book ( id = 1 , title = "DSA with Java" , author = "Puneet Kumar Singh" , description = "A comprehensive guide to Data Structures and Algorithms using Java." , rating = 5 , published_date = 2014 ), Book ( id = 2 , title = "Python Programming" , author = "Puneet Kumar Singh" , description = "An introduction to Python programming for beginners." , ...