Your code makes no sense. I would suggest you start by looking in the shipping examples. Open the Example Finder and on the Browse tab, expand Fundamentals>Arrays and Clusters. Open Separate Array Values. It doesn't do exactly what you want but by replacing the less than zero function, you can have it. I would strongly recomend you not do equal comparisons on floating point numbers, though. Convert your array to integers.