NSInteger num = self.navigationController.viewControllers.count;
if (num > 3) {
UIViewController *popVC = self.navigationController.viewControllers[num - 3];
[self.navigationController popToViewController:popVC animated:YES];
}
以下是文章链接
http://www.jianshu.com/p/c4d1eb226eaf