用let year = (("\(birthday.date)" as NSString).substringWithRange(NSMakeRange(0, 4))).toInt()!来获取出生年份,然后用let now = (("\(NSDate())" as NSString).substringWithRange(NSMakeRange(0, 4))).toInt()!减去也可以~
2015-08-02
var vc = segue.destinationViewController as! DetailViewController 我现在的版本需要在as后加!强制向下转型了,你们的也是么
2015-08-01