Forums Register Login

Output formatting

+Pie Number of slices to send: Send
Further to my previous post, I now need to format the output of the program to look like the following:

Worker's projected yearly gross salary : XXXXXX.XX

Superannuation contribution
Employer contribution : XXXXXX.XX
Employee contribution : XXXXX.XX

Worker's weekly assessable income : XXXXXX.XX
Weekly income tax : XXXXXX.XX
Medicare levy : XX.XX
Child Support contribution : XXX.XX
: ========
Take home pay : XXX.XX

Now the actual outputs are fine but I need to get the extra lines in place and the :======= as shown in the 2nd last line. I am not too sure how to go about this, can anyone point me in the right direction.

My output current appears like this:



Although in realty the figues are actually in line.

Thanks in advance!
+Pie Number of slices to send: Send
And what are you using to output these lines?
+Pie Number of slices to send: Send
Hi, the following is the code...



Thanks
+Pie Number of slices to send: Send
Well, it appears that you're asking to output a blank line and a line with dashes or equals signs in it. I don't know why you can't just use System.out.println("") and System.out.println("=============>") or whatever.

rc
+Pie Number of slices to send: Send
Thanks Ralph, I had though about doing that but wasn't too sure if there was a particular way of doing these types of things. (I am only in my 3rd week of doing these types of programs).

I will give it a go.

Thank you for your help
If you are using a rototiller, you are doing it wrong. Even on this tiny ad:
a bit of art, as a gift, that will fit in a stocking
https://gardener-gift.com


reply
reply
This thread has been viewed 808 times.
Similar Threads
Passing data to methods
Issues with if else statement
Money, Tax, Life Insurace, Loans, Mutual Funds, Stock Market, phew!
Java Program....Coding Help....Please!
Who pays the employment tax for H1B holders?
More...

All times above are in ranch (not your local) time.
The current ranch time is
Mar 28, 2024 04:47:30.