sefiroths
sefiroths

Reputation: 1563

saving and reading a file of integers in objective-c

i have an array like: int array[500][2]; suppose

array[0][0]=1;  array[0][1]=2;
array[1][0]=2;  array[1][1]=4;
array[2][0]=4;  array[2][1]=6;

.... i'd like to write a file and read after saving it... do i have to pass all values to NSString? thanks

Upvotes: 1

Views: 137

Answers (1)

bbum
bbum

Reputation: 162712

do i have to pass all values to NSNumber

No. You could use fread()/fwrite(), if you wanted. Or you could encode as XML.

Not enough context to be more specific.

Upvotes: 1

Related Questions