• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

reverse array

 
Gabriel White
Ranch Hand
Posts: 233
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hey Yall, long time no talk...
I'm trying to get this simple array reversal to work.
It correctly fills in all of the random numbers, but then I want it to output the same numbers in reverse order WITHOUT changing the for loop.
Here is my code. I know the last part is wrong, I have just been trying different ideas to get it to work.
I also know that I need to setup a temp variable and subtract 1 from the myArray array to print correctly. Something like that.
Thanks in advance.
 
Ramesh Donnipadu
Ranch Hand
Posts: 100
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I guess you are trying to print the contents of the Array in reverse order. If so, could you try this?

[ January 13, 2004: Message edited by: Ramesh Donnipadu ]
 
Gabriel White
Ranch Hand
Posts: 233
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks Ramesh, I couldn't remember it. I had it typed out like that before, but I guess I just did something else wrong.
Thanks for your help.
Steve
 
Consider Paul's rocket mass heater.
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic