Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

C can be a cryptic language. The International Obfuscated C Code Contest pokes fun at this. Entries are to be C programs that are as

C can be a cryptic language. The International Obfuscated C Code Contest pokes fun at this. Entries are to be C programs that are as cryptic, obscure, and difficult to read as possible; but they must compile successfully (usually with warnings!) and do something.
The judges ruled that David Korns entry from the 4th International Obfuscated C Code Contest was the best one-line entry ever received up to then. Here it is:
main(){ printf(&1["\021%six\12\0"],(1)["have"]+"fun"-0x60);}
Please simplify each argument of the printf. You need to explain why the program does what it does.
Note: If you compile this program on the CSIF, you will get numerous warnings. You do not need to fix them (in fact, you should not) or explain them.
Simplify the first argument in the printf. Explain in detail your analysis.
Simplify the second argument in the printf. Explain in detail your analysis.
What does the printf print, and why?

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

More Books

Students also viewed these Databases questions