I am extremely new to Objective-C and iOS programming. The tutorial I am using has the following syntax for creating a NSString array representing the ranks of a deck of cards. My question is whether it is valid:
NSArray *rankStrings =@[@"?",@"A",@"2",@"3",...,@"10",@"J",@"Q",@"K"];
The reason for the question is that xCode is giving a red exclamation mark which says Expected expression
. I don't want to mis-learn that ellipses are unacceptable. So I am asking here to know exactly why I am getting the error.
For comparison, python has range functions for creating lists. So maybe the ellipse here is comparable: I don't know. So can someone point out what's wrong with the declaration? Whether it is the ellipse, or how I am using them, or something else?