Starrbuckk
New Member
- Joined
- Mar 24, 2016
- Messages
- 19
Hi,
I need to find the position of 2 values, lets call them "X" and "Z", on an array.
I've got a board that repeats X and Z multiple times, and what i wanted is the column position of the first time X presents itself on the Row im looking, then the first time Z presents itself on the same row, then i want the second time X presents itself again after Z, and the same thing for Z.
Ex.
XXXZZZZXXZZXX
X=1
Z=4
X=8
Z=10
X=11
So i was thinking i need some formula that changed the array according to the last position found(Array column+1/4/8) but maybe theres a simpler way.
Thanks in advance.
I need to find the position of 2 values, lets call them "X" and "Z", on an array.
I've got a board that repeats X and Z multiple times, and what i wanted is the column position of the first time X presents itself on the Row im looking, then the first time Z presents itself on the same row, then i want the second time X presents itself again after Z, and the same thing for Z.
Ex.
XXXZZZZXXZZXX
X=1
Z=4
X=8
Z=10
X=11
So i was thinking i need some formula that changed the array according to the last position found(Array column+1/4/8) but maybe theres a simpler way.
Thanks in advance.