
Mailing List Archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[tlug] C puzzle
- Date: Fri, 26 Jul 2002 01:29:47 +0900 (JST)
- From: Tod McQuillin <devin@example.com>
- Subject: [tlug] C puzzle
This C program:
main() {
int i, n=20;
for(i = 0 ; i < n ; i--)
printf("-");
}
Can be modified into a correct program for printing 20 '-' characters in a
row by replacing a single character of the code.
In fact, there are three different ways to do it.
Who can find all three?
(Not strictly linux related but seemed vaguely on topic :-) )
--
Tod McQuillin
Home |
Main Index |
Thread Index