Question: a. Create a program that allows a user to input customer records (ID number, first name, last name, and balance owed) and save each record

a. Create a program that allows a user to input customer records (ID number, first name, last name, and balance owed) and save each record to a file. Save the program as WriteCustomerList.java. When you execute the program, be sure to enter multiple records that have the same last name because you will search for repeated first names in part d of this exercise. 

b. Write an application that reads the file created by the WriteCustomerList application and displays the records. Save the file as DisplaySavedCustomerList.java. 

c. Write an application that allows you to enter any ID number, reads the customer data file created in Exercise 5a, and displays the data for the customer. Display an appropriate message if the ID number cannot be found in the input file. Save the file as DisplaySelectedCustomer.java. 

d. Write an application that allows you to enter any last name and displays  all the data for customers with the given last name. Display an appropriate message if the name cannot be found in the input file. Save the file as DisplaySelectedCustomersByName.java. 

e. Write an application that allows you to enter any purchase amount and displays all the data for customers with balances greater than the entered value. Display an appropriate message if no customers meet the criteria. Save the file as DisplaySelectedCustomersByBalance.java.

Step by Step Solution

3.44 Rating (167 Votes )

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock

a import javaniofile import javaio import static javaniofileAccessMode import javautilScanner public class WriteCustomerList public static void mainString args Path file PathsgetCJavaChapter13Customer... View full answer

blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Java Programming Questions!