C Program Macro Translation
#include <stdio.h> #define This int #define program main() #define will { #define Prompt int x; #define the int y; #define user scanf #define to ( #define enter #define two "%i %i" #define numbers =, &x, &y); #define Print printf #define their ("%i", #define sum (x + y); #define Exit return #define with #define exit #define code #define That s; #define all } This program will Prompt the user to enter two numbers Print their sum Exit with exit code 0 Thats all
A humorous C program uses preprocessor definitions to make the source code read like plain English instructions. The joke is that the macros disguise valid C syntax as a simple sentence describing exactly what the program does, ending with the misspelled “Thats all.”
- @profunctor_io / 4753 2020-06-12
- Type
- image
- Size
- 470×536 · 37.4 KiB
- Mood
- clever, absurd
- Language
- en
- Added