02-Minimalist C Language Program

Source: Internet
Author: User

Learning Focus:

  • Specific analysis
  • Detailed explanation

Learning content:

1. #include <stdio.h>//file preprocessing, including standard input/output library

int main ()//C language Program main function, start entry

{

printf ("Hello world\n"); /*c the content of the language, print output on the screen */

return 0;

}

#include <> loads the code in the Stdio.h header file containing the standard input and output library functions into the program before the program executes, enabling the compiler to find the required function.

int main () tells the compiler that this is a main function that returns the type int.

{} represents the beginning and end of a program code block.

printf () is the C standard output function, "" double quotes tell the compiler what to output, ' \ n ' is a newline character, the cursor moves to the next line of the screen, '; ' semicolons indicate the end of our command or the end of this paragraph.

Finally, at the end of the program, the main function returns a value to the operating system, telling the operating system that the program is successful, and generally returning 0 to indicate that the program is running successfully.

02-Minimalist C Language Program

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.