|
|
|
|
|
February 10th, 2001, 10:59 PM
|
|
Captain
|
|
Join Date: Jan 2001
Location: Chandler, AZ, USA
Posts: 921
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
quote: Originally posted by raynor:
Help! I'm having a seizure!! Someone, quick! Bring me an obfuscated C program to look at! Better if you put the entire program on just one line!
Programming Axioms:
1. Every program can be reduced by one line.
2. Every program has at least one bug.
Corollary:
Every program can be reduced to one line that doesn't work!
Of course, there are those of us who have to go back and maintain those obfuscated programs (he says, sitting at work on a Saturday, taking a break from fighting with 5-10 year old LISP code that was written by people who thought that all variables should be global in scope ) and we WILL find you eventually!
[This message has been edited by Alpha Kodiak (edited 10 February 2001).]
__________________
My SEIV Code: L++++ GdY $ Fr+++ C-- S* T? Sf Tcp A%% M+++ MpT RV Pw+ Fq Nd- RP+ G++ Au+ Mm++(--)
Ursoids of the Galaxy, unite!
|
February 11th, 2001, 01:53 AM
|
|
Major
|
|
Join Date: Aug 2000
Posts: 1,246
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
#include <stdio.h>
void main()
{
printf("Go lay an egg, you bumbling freak!\n");
}
__________________
When a cat is dropped, it always lands on its feet, and when toast is dropped, it always lands with the buttered side facing down. I propose to strap buttered toast to the back of a cat. The two will hover, spinning inches above the ground. With a giant buttered cat array, a high-speed monorail could easily link New York with Chicago.
|
February 11th, 2001, 02:03 AM
|
|
Captain
|
|
Join Date: Jan 2001
Location: Texas
Posts: 830
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
quote: Originally posted by Instar:
#include <stdio.h>
void main()
{
printf("Go lay an egg, you bumbling freak!\n");
}
Basic syntax is correct. But this entry won't even earn third prize in an obfuscated C contest. Maybe if you'd at least written it as:
#include <stdio.h>
void main(){printf("Go lay an egg, you bumbling freak!\n"); }
|
February 11th, 2001, 02:07 AM
|
|
Captain
|
|
Join Date: Jan 2001
Location: Texas
Posts: 830
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
quote: [b] Of course, there are those of us who have to go back and maintain those obfuscated programs (he says, sitting at work on a Saturday, taking a break from fighting with 5-10 year old LISP code that was written by people who thought that all variables should be global in scope ) and we WILL find you eventually!
Don't you wish that you could convince your boss that in most cases, it really is easier to write the whole thing from scratch than try to figure out what the other guy was thinking?
'Write all your programs as if the next guy to work on it is an axe-murderer who knows where you live.'
|
February 11th, 2001, 12:55 PM
|
Private
|
|
Join Date: Dec 2000
Posts: 33
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
quote: Originally posted by raynor:
You should ditch *both* of those for Delphi. IMHO, Delphi is the best RAD (Rapid Application and Development) language out there. It has great support for databases, the internet, etc. Oh, and by the way, what do you think SEIV was written in?
SEIV? O-O (Web) COBOL, undoubtedly. I can imagine:
WITH BIG-SHIP-HAVING-LOTS-OF-GUNS DO ...
or something to that effect.
|
February 11th, 2001, 06:18 PM
|
|
Captain
|
|
Join Date: Jan 2001
Location: Chandler, AZ, USA
Posts: 921
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
quote: Originally posted by raynor:
Don't you wish that you could convince your boss that in most cases, it really is easier to write the whole thing from scratch than try to figure out what the other guy was thinking?
'Write all your programs as if the next guy to work on it is an axe-murderer who knows where you live.'
Actually, I have been lucky, and we have been allowed to rewrite most of our multi-million line app over the Last several years. Unfortunately, this was one of those cases where we all (myself included ) thought that it would be easy to migrate this code to our new system. Oh well, live and learn!
__________________
My SEIV Code: L++++ GdY $ Fr+++ C-- S* T? Sf Tcp A%% M+++ MpT RV Pw+ Fq Nd- RP+ G++ Au+ Mm++(--)
Ursoids of the Galaxy, unite!
|
February 11th, 2001, 07:16 PM
|
Corporal
|
|
Join Date: Jan 2001
Posts: 89
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
Instar wrote:
quote:
#include <stdio.h>
void main()
{
printf("Go lay an egg, you bumbling freak!\n");
}
Assuming this is C, main() must return an int. If your compiler accepts void as main()'s return type, you've been lucky. Obviously, this means you'd need to add a return statement returning zero.
Sorry for the nitpick. Seen this very error in college level books and it kinda annoys me knowing we are teaching future programmers bad habits.
[This message has been edited by Zanthis (edited 11 February 2001).]
__________________
-Zan
|
February 11th, 2001, 10:18 PM
|
|
Major
|
|
Join Date: Aug 2000
Posts: 1,246
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
What? I have seen that syntax, but I never understood why. It couldn't be the errorcode thingy returned to DOS, could it? (The exit() function does that)
I have never heard of the main func returning an int, and I'll always declare it void main (Unless its changed and I have to, or someone offers me money)
__________________
When a cat is dropped, it always lands on its feet, and when toast is dropped, it always lands with the buttered side facing down. I propose to strap buttered toast to the back of a cat. The two will hover, spinning inches above the ground. With a giant buttered cat array, a high-speed monorail could easily link New York with Chicago.
|
February 12th, 2001, 02:05 AM
|
|
Captain
|
|
Join Date: Jan 2001
Location: Texas
Posts: 830
Thanks: 0
Thanked 0 Times in 0 Posts
|
|
Re: THE best strategy game of all times! :D
quote: Originally posted by Jon Brave:
SEIV? O-O (Web) COBOL, undoubtedly. I can imagine:
WITH BIG-SHIP-HAVING-LOTS-OF-GUNS DO ...
or something to that effect.
|
Posting Rules
|
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is On
|
|
|
|
|