+ 15

Does anyone have an explanation for the following output of the program :

#include<stdio.h> void main() { printf(6+"hello world\n"); } Output : world

6th Jun 2019, 4:35 PM
Manoj
Manoj - avatar
5 Respuestas
+ 12
~swim~ Thank you
6th Jun 2019, 4:43 PM
Manoj
Manoj - avatar
+ 4
Adding int 6 to the string hello world makes the pointer shift to its 6th position (including the space)
29th Jun 2019, 11:10 PM
Shristi Singh
Shristi Singh - avatar
+ 3
6+"hello world" means increment the Pointer by 6 places. So your output is world
7th Jun 2019, 12:57 PM
Arun
Arun - avatar