Computer Science 121
Assignment 7
Due: April 11, 2001

For this assignment you are to rewrite program 4 using a StringTokenizer to read the data. Read the computer's name, price and shipping charge all on the same line, separated by spaces. Use this data to calculate the tax and the total bill. As before, display this on the screen, nicely formatted.

Use the Store Example that uses a StringTokenizer to see the methods you will need. You will not need a loop, however, since all the data will be on the same line, and each piece will be assigned to a separate variable.

Calculate the total cost of the computer in a separate method as before. Use the value of $0.0825 for the sales tax. Calculate the sales tax separately from the total so that you will be able to print it out.

And as before, display the data on the screen. This should be in the form of a bill that shows the name, price, tax, shipping charge and total. Make sure that each number is labeled. Format your output using the method, decimals, from the KeyboardReader.