I have NSArray
. I have some value inside that array.
NSArray *testArray = [NSArray arrayWithObjects:@"Test 1", @"Test 2", @"Test 3", @"Test 4", @"Test 5", nil];
NSLog(@"%@", testArray);
Result is like bellow :
(
"Test 1",
"Test 2",
"Test 3",
"Test 4",
"Test 5"
)
Now I want the result like this :
(
"Test 3",
"Test 5",
"Test 1",
"Test 2",
"Test 4"
)
Is there any way to do it without re-initialize the array? Can I swap the value of this array ?