#include <iostream> #define NDEBUG //关闭断言 #include <cassert> using std::cout; using std::endl; int main(){ int x=0; int y=5; for(x=0;x<20;x++){ cout << "x= " << x << " y= "<<y<<endl; assert(x<y); } return 0; }
原文:http://www.cnblogs.com/mengfanrong/p/3885778.html