Practice 1-1 running the "Hello, World" program in your own system. Then deliberately remove part of the program, to see what error messages will be obtained.
The code is as follows:
#include <stdio.h> // contains information about the standard library. int main () // defines a function named Main, which does not accept parameter values. { printf ("Hello, world\n"); // The man function calls the library function printf to display a sequence of characters. getch (); // Prevent the console from flashing through, you need to accept any characters after you close the console. return0; // returns a shape to the execution environment, and 0 represents a successful execution. }
Personal Understanding:
As a classic Hello, the world program, each line of code is worth thinking about, you can go to browse the Stdio.h library has those functions.
When VS2013-type code is executed, the console flashes past, and VS2013 does not join the "Enter any key off" function in VC6.0.
Resolves the issue after adding the Getch () function.
C Programming language Exercises 1-1