import java.io.*; import java.util.Scanner; public class Main { public static void main(String[] args) throws FileNotFoundException{ System.out.print("Please input the file pathname: "); Scanner s = new Scanner(System.in); String filePathName = s.nextLine(); s.close(); // Part (A) Library library = new Library(filePathName); Book b1 = library.getBook(0); Book b2 = library.getBook(1); System.out.println(b1); b1.printRecord(); // Part (B) Member m = new Member("Mary"); Member p = new Member("Paul"); Member w = new Member("Wendy"); m.borrow(b1); b1.printRecord(); b2.printRecord(); p.borrow(b1); p.borrow(b2); w.returnBook(b1); m.returnBook(b1); p.borrow(b1); // Part (C) library.listByWriter("Shakespeare"); library.listByWriter("Lewis Carroll"); m.askMyLoans(library); p.askMyLoans(library); w.askMyLoans(library); } }