A good answer might be:

No, line contains the characters that were converted into integers. Might as well use them to echo what the user entered. (You could also use the integer variables, which would be converted back to characters before echoing.)


A Run of the Modified Program

Here is a sample run of the modified program:

C:\users\default\JavaLessons>java Discount > discount.out

100
50

C:\users\default\JavaLessons>type discount.out
Enter list price in cents:
List price:100
Enter discount in percent:
Discount:50
Discount Price: 50

C:\users\default\JavaLessons>

QUESTION 12:

What happened to the previous version of the file discount.out in the current subdirectory?