C++ Print 1 to 100 without using loop, recursion, goto

:smiley: :smiley: :smiley:
Just for fun!

http://www.quora.com/How-can-I-print-1-to-100-in-C++-without-a-loop-GOTO-or-recursion

2 Likes

Phải thêm cái tag fun vào, ko ăn gạch chết :smiley:

1 Like
int main() {
printf("1\n");
printf("2\n");
...
printf("100");
}

:penguin:

3 Likes

Rất cổ điển nhưng chính xác :grinning:

1 Like
83% thành viên diễn đàn không hỏi bài tập, còn bạn thì sao?