"C and Pointers"--1

Source: Internet
Author: User

Translation steps:
1, each source file that makes up the program is converted into the target code by compiling separately;
2, each target code is bundled together through the linker to form a single complete executable program.
Note: The linker can also link the functions that are used (whether C-Standard or programmer-written) to the program.
Compile process:
1, pre-processor processing: Perform some text operations (#define和 # include text substitution);
2, the source code after parsing: Judge the meaning of the sentence;
3, generate the target code;
If you add an option that requires optimization, the optimizer optimizes the target code.
Perform:
1, the program is loaded into memory: This step is generally done by the operating system, are those that are not stored in the heap and the stack has not yet initialized data to obtain the initial value;
2, program execution begins
3, program termination: Possible success may fail;
Note: Run-time stacks: Local variables and return addresses used to store functions; static memory: Data stored in static memory retains their values throughout the execution of the program
Declaration and definition: a function declaration describes the data type and return type that the function will manipulate, and the function definition is the step that needs to be performed.
Escape characters:
\a Bell (BEL)
\b Backspace (BS)
\f page Break (FF)
\ n line break (LF)
\ r Enter (CR)
\ t Horizontal tabulation (HT)
\v Vertical tabulation (VT)
\ \ represents a backslash character ' \ '
\ ' represents a single quotation mark (apostrophe) character
\ "represents a double-quote character
\? Represents a question mark
A/s null character (NULL)
\ddd 1 to 3 octal digits for any character three-bit octal
\xhh 1 to 2 hexadecimal representation of any character two-bit hexadecimal
Comments:
/* starts with; */ends, and all is commented out. The vast majority of annotations are made up of blocks.
Identifier:
The names of variables, functions, types, etc., consist of letters, numbers, and underscores, and cannot begin with a number; there is no limit to the length of identifiers, but the standard allows the compiler to ignore characters after 31, and the C language is sensitive to the case of letters.
Good programming Style: improve the readability of the program and make it easier to maintain.

"C and Pointers"--1

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.