-
array program help
i'm new to this array thing in java so i'm still trying to find how to make one
could someone help me make a program like this:
it's supposed to input the array size and the numbers
(the user is the one to input the numbers on it)
like this:
Enter the array size: 5
i[0] = 1
i[1] = 2
i[2] = 3
i[3] = 4
i[4] = 5
after that it should show the ascending and descneding orders of the numbers
like this:
the ascending order is : 1,2,3,4,5
the descending order is : 5,4,3,2,1,
what is the value of: 2
it should output the value of array number 2
like this:
the value of i[2] is 3
and at the end it should ask if it wants to try again y/n
(it will output again the "what is the value:" question if yes, if no then exit)
any help will be appreciated, i really need to make this program for my assignment but i'm still confused on the whole array thing. thanks in advance
-
Re: array program help