te a class called CustomerListerwith a mainmethod that instantiates an array of Stringobjects called customerName. The array should have room for five Stringobjects. Use an initializer list to put the following names into the array:Cathy Ben Jorge Wanda FreddieUse newto create a second doublearray called customerBalancein the mainmethod. Allow room for five customer balances, each stored as a double.In the loop that prints each customer name, add some code to prompt the user to enter a balance for that customer. Read the keyboard input with a Scannerobject. Use the following balances for the input:100.00234.562.4932.32400.00After all the balances have been entered, print out each customer and his/her balance.

EBK JAVA PROGRAMMING
9th Edition
ISBN:9781337671385
Author:FARRELL
Publisher:FARRELL
Chapter8: Arrays
Section: Chapter Questions
Problem 9PE
icon
Related questions
Question

Create a class called CustomerListerwith a mainmethod that instantiates an array of Stringobjects called customerName. The array should have room for five Stringobjects. Use an initializer list to put the following names into the array:Cathy Ben Jorge Wanda FreddieUse newto create a second doublearray called customerBalancein the mainmethod. Allow room for five customer balances, each stored as a double.In the loop that prints each customer name, add some code to prompt the user to enter a balance for that customer. Read the keyboard input with a Scannerobject. Use the following balances for the input:100.00234.562.4932.32400.00After all the balances have been entered, print out each customer and his/her balance. 

Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps

Blurred answer
Knowledge Booster
Passing Array as Argument
Learn more about
Need a deep-dive on the concept behind this application? Look no further. Learn more about this topic, computer-science and related others by exploring similar questions and additional content below.
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT
Programming Logic & Design Comprehensive
Programming Logic & Design Comprehensive
Computer Science
ISBN:
9781337669405
Author:
FARRELL
Publisher:
Cengage
C++ Programming: From Problem Analysis to Program…
C++ Programming: From Problem Analysis to Program…
Computer Science
ISBN:
9781337102087
Author:
D. S. Malik
Publisher:
Cengage Learning
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,