Write a function to delete a node containing Book's information from a dynamically allocated stack of Books implemented with the help of the following structure.
struct BOOK{ int BNo; char BNAME[20]; BOOK*NEXT;};
struct BOOK{ int BNo; char BNAME[20]; BOOK*NEXT;};
void deleteBook(BOOK &a){
//we delete next BOOK after BOOK a
a.NEXT = (a.NEXT)->NEXT;
}