I have a NSArray that looks like this:
NSArray *array = {@"1.100.2", @"23465343", @"1.100.1", @"46535334", @"1.0.03", @"24353454" ...};
I need to pair every 2 strings into an array within an array like this:
NSArray *pairedArray = {{@"1.100.2", @"23465343"}, {@"1.100.1", @"46535334"}, {@"1.0.03", @"24353454"}, ...};
The array is dynamic.
I think there's a for
statement I can use but can't remember. Something like for (uint i = 0; i < len - 1; i += 2)
Any help would be appreciated.