anessen 10 Posted July 24, 2012 Quick question (ish :D) I have an array like this: myArray = [["item one", "item two"], [], [], ["blah", "blah"]]; I would like to be able to check to see if (myArray select _x) is an empty array, like (myArray select 1) would be. (myArray select 1) == [] //Doesn't work :( Share this post Link to post Share on other sites
mikie boy 18 Posted July 24, 2012 you could possibly try counting the array? Share this post Link to post Share on other sites
cuel 25 Posted July 24, 2012 Yup. Something like this I'd guess. _array = [[1],[2],[]]; _element = _array select 2; hint format ["elements of nested array element: %1",count _element]; Share this post Link to post Share on other sites
samatra 85 Posted July 24, 2012 You can't compare arrays with == and others, you will have to walk through each array item and compare it by yourself. Share this post Link to post Share on other sites