NSDictionary *infoDict = [[NSBundle mainBundle] infoDictionary];
NSString *vison = infoDict[@"CFBundleVersion"];
// NSString *vison = @"1.2.5";
NSString *vison2 = @"1.13.4";
if ([vison compare:vison2 options:NSNumericSearch] == NSOrderedDescending)
{
NSLog(@"%@ is bigger",vison);
} else {
NSLog(@"%@ is bigger",vison2);
}
网友评论