nsmutablearray - How to create multidimensional array in swift? -


this question has answer here:

i'm trying push array type object special index inside array in new swift lang apple. should = [ [...], [...], ...], i've read in docs - nsmutablearray type assigned variable automatically if it's var, in playground throws me errors:

var arr = [];  arr[0] = []; // error: cannot assign result of expression  arr.insert([], atindex:0) // error: 'nsarray' not have member named 'insert' 

var array2d: [[int]] = [[1,2,3,4],[5,6,7,8]] 

Comments

Popular posts from this blog

database - VFP Grid + SQL server 2008 - grid not showing correctly -

jquery - Set jPicker field to empty value -

.htaccess - htaccess convert request to clean url and add slash at the end of the url -