Amusing C++: funny tricks





3.00/5 (2 votes)
Try this one://Can we print all integers from 1 to 30??/int x = 0;while (x < 30){ _tprintf(_T("X = %d\n"), ++x);}
Try this one:
//Can we print all integers from 1 to 30??/
int x = 0;
while (x < 30)
{
_tprintf(_T("X = %d\n"), ++x);
}