|
Re: oh the java probrlems......help me !!!! multiple problems
|
Posted: May 2, 2002 2:37 AM
|
|
I've just started with Java, so I don't have any ideas for #1 or #3. But I was thinking for #2 that you could try the following:
public class Backwards { public static void main(String[] args) { int[] integer = {1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
// Output integers in reverse order System.out.println("The numbers displayed backwards are: ");
for(int i = 9; i < integer.length && i >= 0; i--) { System.out.print(integer + " "); } } }
You'll probably have to change a few parts of the code, but that works for me.
|
|