去除數(shù)組中重復(fù)的對象
NSArray *newArr = [oldArr valueForKeyPath:@“@distinctUnionOfObjects.self"];
強(qiáng)/弱引用
#define WeakSelf(type) ?__weak typeof(type) weak##type = type; // weak
#define StrongSelf(type) ?__strong typeof(type) type = weak##type; // strong
由角度轉(zhuǎn)換弧度
#define DegreesToRadian(x) (M_PI * (x) / 180.0)
由弧度轉(zhuǎn)換角度
#define RadianToDegrees(radian) (radian*180.0)/(M_PI)