Is there an easy way to programmatically get the alphabet?

前端 未结 5 1356
臣服心动
臣服心动 2021-02-04 12:11

I want an NSArray/NSMutableArray containing all the letters of the alphabet. There must be a quick and easy way, better than typing them all out. For example in PHP

5条回答
  •  一生所求
    2021-02-04 12:53

    Sometimes typing the letters out is the easiest. Here they are as an array:

    NSArray *letters = [@"A B C D E F G H I J K L M N O P Q R S T U V W X Y Z" componentsSeparatedByString:@" "];
    

提交回复
热议问题