1.Xcode快捷键:
Command+[ -> 代码块左移
Comamnd+] -> 代码块右移
Tab -> 接受代码自动完成提示
Esc -> 显示代码提示
Command+B -> 编译
Command+R -> 运行
Control+F -> 前移光标
Control+B -> 后移光标
Control+P -> 光标移到上一行
Control+N -> 光标移到下一行
Control+A -> 光标移到行首
Control+E -> 光标移到行尾
Control+T -> 交换光标左右字符
Control+D -> 删除光标右边的字符
Control+K -> 删除本行
Control+L -> 将光标所在位置置于窗口中央
按住Option双击鼠标 -> 搜索文档
Command+Y -> 激活/禁用断点
Command+Control+Y -> 继续运行
F6 -> 单步跳过
F7 -> 单步跳入
F8 -> 跳出
2.ios生命周期

#import "AppDelegate.h"
@interface AppDelegate ()
@end
@implementation AppDelegate
- (BOOL)application:(UIApplication *)application didFinishLaunchingWithOptions:(NSDictionary *)launchOptions {
NSLog(@"%s", "application:didFinishLaunchingWithOptions: Not runing -> Inactive");
return YES;
}
- (void)applicationDidBecomeActive:(UIApplication *)application {
NSLog(@"%s","applicationDidBecomeActive: Inactive -> active");
}
- (void)applicationWillResignActive:(UIApplication *)application {
NSLog(@"%s", "applicationWillResignActive: active -> Inactive");
}
- (void)applicationDidEnterBackground:(UIApplication *)application {
NSLog(@"%s","applicationDidEnterBackground: Background -> Suspended");
}
- (void)applicationWillEnterForeground:(UIApplication *)application {
NSLog(@"%s","applicationWillEnterForeground: Suspended -> Background -> Inactive");
}
- (void)applicationWillTerminate:(UIApplication *)application {
NSLog(@"%s","applicationWillTerminate: Suspended -> Not runing");
}
@end