Created
October 13, 2011 01:58
-
-
Save jeremytregunna/1283149 to your computer and use it in GitHub Desktop.
Salute to Dennis Ritchie
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
int main(argc, argv) | |
int argc; | |
char** argv; | |
{ | |
char foo[3] = { 'b', 'y', 'e' }; | |
printf("%s\n", foo); | |
return 0; | |
} |
Aha, extremely dry computer humor. :-)
And of course, in true C style, it only sometimes prints garbage when printed out. :-)
Indeed. Was either that code, or something like this:
printf("bye%s\n");
To salute Dennis Ritchie :)
Since the code in the gist is unlikely to trigger a compiler warning (maybe with -Wall
) I opted for it instead.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
That was the idea. It'll produce garbage when printed out. :)