Determine Output:
void main(){ char *p; p="%d\n"; p++; p++; printf(p-2, 300);}
void main(){ char *p; p="%d\n"; p++; p++; printf(p-2, 300);}Determine Output:
void main(){ char *p; p="%d\n"; p++; p++; printf(p-2, 300);} Correct Answer 300
The pointer points to % since it is incremented twice and again decremented by 2, it points to '%d\n' and 300 is printed.
মোঃ আরিফুল ইসলাম
Feb 20, 2025