LabVIEW

cancel
Showing results for 
Search instead for 
Did you mean: 

reverse in rows in a 2-d array of string

Solved!
Go to solution

hello

I have a kind of simple question.but i tried many things and couldnt help.I need to reverse a 2-d array of strings in rows.just to make it clear i make an example:   

 

a b c

d e f

g h i

 

and i want to make it

 

g h i 

d e f

a b c

 

how can i do this?

 

0 Kudos
Message 1 of 8
(5,088 Views)

A for Loop that autoindexes through the array row by row, then builds it back up in reverse order using Build Array and a shift register.

0 Kudos
Message 2 of 8
(5,084 Views)

Capture.JPG

aputman
0 Kudos
Message 3 of 8
(5,078 Views)

@aputman wrote:

Capture.JPG


Way too Rube-esque.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 4 of 8
(5,068 Views)

@billko wrote:

@aputman wrote:

Capture.JPG


Way too Rube-esque.


Because this is a simplified form of OpenG where there is an option to reverse by columns....hence the extra code.  My bad.....sheesh. Smiley Happy

aputman
0 Kudos
Message 5 of 8
(5,058 Views)

@aputman wrote:

@billko wrote:

@aputman wrote:

Capture.JPG


Way too Rube-esque.


Because this is a simplified form of OpenG where there is an option to reverse by columns....hence the extra code.  My bad.....sheesh. Smiley Happy


Really?  I would've just used the method described by RavensFan and stuck a transpose 2-D array before and after the loop.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 6 of 8
(5,050 Views)
Solution
Accepted by .mohamad.mah11

Here's what I would do.

 

 

Message 7 of 8
(5,042 Views)

@altenbach wrote:

Here's what I would do.

 

 


Haha that should've occured to me because I first tried what you have there without the transpose 2d arrays and noticed it was doing columns and not rows.

Bill
CLD
(Mid-Level minion.)
My support system ensures that I don't look totally incompetent.
Proud to say that I've progressed beyond knowing just enough to be dangerous. I now know enough to know that I have no clue about anything at all.
Humble author of the CLAD Nugget.
0 Kudos
Message 8 of 8
(5,034 Views)