Fox International sells pre-paid calling card with the following features: Calls to USo 1.2 cents per minute plus a 49 cent connection fee per call Calls to Europeo 2.3 cents per minute plus a 49 cent connection fee per call Calls to Australiao 6.4 cents per minutes plus a 49 cent connection fee per callWrite a program that work out the charges for the month. The program should accept the followinginformation: Account holders name Card number Starting Balance on card For US callso Total number of minutes of all callso Total number of calls made For European callso Total number of minutes of all callso Total number of calls made For Australian callso Total number of minutes of all callso Total number of calls madeYou are NOT expected to error check your inputs for this assignment. (e.g. checking for negative values,etc.). There is NO GST charged on the calls as the GST was paid when the card was purchased.Format of output:Review the test plan to see how the user would like the output to be formatted. Use System.out.printf() toensure values are output with 2 digits of precision.Test Plan (Input and expected output)Input (show user input shown in bold underline)Fox International Calling Card CalculatorEnter account holders name: Harvey WallbangerEnter card number: 4958709-923WAStarting Balance on card:100-----------------------------------------US callsTotal # of US calls: 5Total duration of ALL US calls in minutes: 100European callsTotal # of calls to Europe: 2Total duration of ALL calls to Europe in minutes: 30Australian callsTotal # of calls to Australia: 1Total duration of ALL calls to Australia in minutes: 15-------------------------------------------------------Charge SummaryDescription Calls Min TotalUS Charges 5 100 3.65Euro Charges 2 30 1.67Aussie Charges 1 15 1.45Total 8 145 6.77Card Balance $93.23
Fox International sells pre-paid calling card with the following features:
Calls to US
o 1.2 cents per minute plus a 49 cent connection fee per call
Calls to Europe
o 2.3 cents per minute plus a 49 cent connection fee per call
Calls to Australia
o 6.4 cents per minutes plus a 49 cent connection fee per call
Write a program that work out the charges for the month. The program should accept the following
information:
Account holders name
Card number
Starting Balance on card
For US calls
o Total number of minutes of all calls
o Total number of calls made
For European calls
o Total number of minutes of all calls
o Total number of calls made
For Australian calls
o Total number of minutes of all calls
o Total number of calls made
You are NOT expected to error check your inputs for this assignment. (e.g. checking for negative values,
etc.). There is NO GST charged on the calls as the GST was paid when the card was purchased.
Format of output:
Review the test plan to see how the user would like the output to be formatted. Use System.out.printf() to
ensure values are output with 2 digits of precision.
Test Plan (Input and expected output)
Input (show user input shown in bold underline)
Fox International Calling Card Calculator
Enter account holders name: Harvey Wallbanger
Enter card number: 4958709-923WA
Starting Balance on card:100
-----------------------------------------
US calls
Total # of US calls: 5
Total duration of ALL US calls in minutes: 100
European calls
Total # of calls to Europe: 2
Total duration of ALL calls to Europe in minutes: 30
Australian calls
Total # of calls to Australia: 1
Total duration of ALL calls to Australia in minutes: 15
-------------------------------------------------------
Charge Summary
Description Calls Min Total
US Charges 5 100 3.65
Euro Charges 2 30 1.67
Aussie Charges 1 15 1.45
Total 8 145 6.77
Card Balance $93.23
Trending now
This is a popular solution!
Step by step
Solved in 2 steps with 1 images