Feb 7, 2017, 2:18 PM
Post #5 of 6
Re: [Laurent_R] how to get each element of array to print out
[In reply to]
I assumed that the OP moved the print statement as a debugging aid. When I ran the code that was posted, I got exactly what I expected. I then moved the print 'back' to its normal position to reduce the clutter. Neither version reproduces the problem that he reported.
This works, but only prints one line "Inventory3x." How do I get it to print Inventory1x and Inventory2x one time as well?
Perhaps he mean the print statement (in the right place) to do this:
printf "THESE ARE THE %s\n" x @lines, @lines;
THESE ARE THE Inventory1x
THESE ARE THE Inventory2x
THESE ARE THE Inventory3x