The I/O from a sample program run is as follows:
Script started on Fri Apr 23 12:23:41 2004 prompt >> java ComoundInterest Welcome to the Compound Interes Program --------------------------------------- Input Principal: 1000 Input Interest Rate: 0.12 Input No Of Years: 4 The parameter values you have entered are: Principal = 1000.0 Interest Rate = 0.12 No Years = 4.0 ======================== Future Sum = 1573.52 prompt >> exit Script done on Fri Apr 23 12:23:59 2004
Notice how I have used the method System.out.print() to put the prompt and the string input on the same line.