C Program to Run the “hello, world” program on your system.
Program Statement :
Run the “hello, world” program on your system. Experiment with leaving out parts of the program, to see what error messages you get.
C Program Solution : Example 1
1 2 3 4 | #include<stdio.h> main() { printf("hello, world"); } |
Output :
1 | hello, world |
C Program Solution : Example 2
1 2 3 4 | #include<stdio.h> main() { printf("hello, world") } |
Output :
1 | Compile Error : Statement Missing Semicolon |
C Program Solution : Example 3
1 2 3 4 | #include<stdio.h> main() { printf("hello, world\n"); } |
Output :
1 2 | "hello, world" will be printed on screen and cursor moved to next line |