Trying to figure out how to create 3 columns for subtraction, using an overloading method. First column first number and largest, second number smaller number, and 3rd column what the first number subtracting the second number equals. I wasn't doing bad with begginer stuff in java till I started this and just can't figure out what I need to do. The actual instructions are:
Write overloaded Java methods that return the difference of two integers. Your methods should contain the logic to return the difference of the (larger - smaller).
Parm 1 TypeParm 2 TypeReturn Type
int int int double double double int double double double int double
Anyone able to help out. I know it is probably fairly easy, but I am just not figuring it out using the book I have. [ October 21, 2007: Message edited by: Walt Lee ]
The soul is dyed the color of its thoughts. Think only on those things that are in line with your principles and can bear the light of day. The content of your character is your choice. Day by day, what you do is who you become. Your integrity is your destiny - it is the light that guides your way. - Heraclitus
First, take a look at the signature, does it match the signature as required in your assignment -- particularly the return type.
But... the problem with your program is likely the printf() method. Take a look at the javadoc for that method again. The first parameter is the format string, which is just printing the heading -- it makes no mention of the parameters that follow it.