#include "stdafx.h" int _tmain(int argc, _TCHAR* argv[]) { int a = 1, b = 1, c = 0; int max = 0x7FFFFFFF; printf("%d\n", max);// 打印一下整型的最大值 while(1) { if(c == 0) { printf("%d %d ", a, b); } c = a + b; if(c < 0) break; printf("%d ", c); a = b; b = c; } return 0; }
原文地址:http://www.cnblogs.com/wxzy/p/3849959.html