Currymunch
Member
- Joined
- Jan 21, 2008
- Messages
- 13
- Programming Experience
- Beginner
Hope everyone is well, I was wondering if anyone knew the answer to the following;
Im looking to flip an array horizontally so that an array of characters ie -- 123 becomes 321 without using a swap (introducing temp variables that slotting in).
Another solution would be to flip the string of numbers that i'm entering in so i enter in 123 in the textbox and then it gets flipped, then i use the mod operator to get into the array later (like a sneaky method of the above)
The only way i can think of doing it thus far is using lots of if statements to find the length of the string then performing a swap function : seems rater messy.
Thanks in advance
Im looking to flip an array horizontally so that an array of characters ie -- 123 becomes 321 without using a swap (introducing temp variables that slotting in).
Another solution would be to flip the string of numbers that i'm entering in so i enter in 123 in the textbox and then it gets flipped, then i use the mod operator to get into the array later (like a sneaky method of the above)
The only way i can think of doing it thus far is using lots of if statements to find the length of the string then performing a swap function : seems rater messy.
Thanks in advance