Keyboard shortcuts

Press ← or → to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Library with Author

Step-by-Step Enhancements

  1. Define the Author Case Class: Add a case class to represent an author with attributes like name and nationality.

  2. Update the Book Case Class: Modify the Book case class to include an Author.

  3. Create a Shopping Basket Class: Define a class to manage the shopping basket, including adding books and calculating the total cost.

  4. Update the Library Management System: Update the main application to include the new Author case class and the shopping basket functionality.