- #import <Foundation/Foundation.h>
 
 - int main(int argc, const char * argv[])
 
 - {
 
 -         const char *words[4] = { "aardvark", "abacus", "allude", "zygote" };
 
 -         int Count = 4;        
 
 -         for (int i = 0; i < Count; i++)
 
 -                 NSLog (@"%s is %lu characters long", words[i], strlen(words[i]));
 
 -     return 0;
 
 - }
 
  复制代码 
字符串就是数组, 定义字符串数组还要用到指针, 有时候又用二维数组. 真是晕啊! |   
        
 
    
    
    
     
 
 |