05-29-2014 01:46 PM - edited 05-29-2014 01:46 PM
Yes, if you have a FOR loop, the final array size is know, so preallocation might be more efficient as Lynn pointed out.
If you don't know the final array size (e.g. using a while loop), you code can still be simplified:
here's how it would look like, clean up a little bit.
05-29-2014 03:52 PM
Thank you! It seems so easy now..
05-29-2014 04:38 PM - edited 05-29-2014 04:42 PM
So I'm down to the last step. The program I've attached does what I want except I can't plot the final array. I apologize if the programming is messy, I'm just trying to throw this together before the day is over.
So to clarify I'm just trying to plot the "element" cluster. I need to convert it to something the graph can read but it's telling me "You have connected to a polymorphic terminal that does not accept this wire type " When I try to convert it to an array.
EDIT: I've got it. Just needed to unbundle it. Thanks everyone!