I reread the explanation a couple of times, but I still don't understand what these are. Can someone explain to me what an argument and a format string are?
2 Answers
I'll answer before this question gets closed or downvoted too severely for not being specific or having much detail:
Format strings are used for passing 1-or-more arguments to compose a NSString object.
Check out this useful Apple documentation on String format specifiers.
Arguments are the parameters passed into a method or function.
And if you are talking about some compiler errors, such as the "format not a string literal and no format arguments" error you might see when trying to log stuff via NSLog
, check out the answers to this very related question.

- 1
- 1

- 88,797
- 17
- 166
- 215
An argument is a variable value that you pass to something else, generally a method. In plain English, if you were to say "go run around the block 30 times", 30 would be the argument. Depending on your method, maybe "block" and "run" would be arguments as well, where you could also say "go walk around the house 10 times".
A format string is a string that describes how to format a series of arguments. These generally take the form of a string that has certain placeholders in it where the arguments will be shown in the result.

- 5,231
- 24
- 32