Dark Horse programmer-C Study Notes-first c language program,-C Study Notes
------- Ios training, android training, and java training. We look forward to communicating with you! ----------
I. The first C Language ProgramSource code: Compile the code written by the programmer: translate the source code into 0 and 1 to generate one. o file target file link: the target file is integrated with the C language library file to generate. shortcut for running the out file: command + R
Code Demonstration:
1 # include <stdio. h> 2 int main (int argc, char * argv []) {3 4 printf ("hello heima"); 5 6 return 0; 7 8}
Conclusion: 1. the basic unit of C language programs is function 2. the program entry is the main function 3. each statement must be followed by a semicolon, indicating that the statement is complete. only Chinese and Chinese characters can appear in the middle of the comment and double quotation marks, and none of the other positions can be 5. print Output content must be written in the middle of double quotation marks in English. 6. the method name must be followed by ()
Ii. identifier naming rules1. It can only contain 26 English letters, 10 Arabic numerals, 0 ~ 9. Underline Composition 2. Strict case sensitivity, for example, test and Test are two different identifiers 3. Cannot start with a number 4. Cannot Use keywords as identifiers