How do you write a program which produces its own source
code as its output?
Answer Posted / abhinav gupta
Try to google....quine Problem...
one solution is
main(){char *c="main(){char
*c=%c%s%c;printf(c,34,c,34);}";printf(c,34,c,34);}
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
a direct address that identifies a location by means of its displacement from a base address or segment a) absolute address b) relative address c) relative mode d) absolute mode
Do you know the difference between malloc() and calloc() function?
Explain how can I write functions that take a variable number of arguments?
What is extern keyword in c?
How do you list a file’s date and time?
What do header files do?
Is c language still used?
cin.ignore(80, _ _);This statement a) ignores all input b) ignores the first 80 characters in the input c) ignores all input till end-of-line d) iteration
Why c is called top down?
What is the difference between struct and union in C?
Explain how can I manipulate strings of multibyte characters?
Write a code to generate a series where the next element is the sum of last k terms.
How pointer is different from array?
using only #include
What are the valid places to have keyword “break”?