1, in order to distinguish the octal system, the hexadecimal difference: eight before adding 0, hex plus x0, such as 058,x059;
2, binary conversion, binary, octal, decimal, hexadecimal conversion between each other. (converted to binary after the other is good conversion)
such as: decimal number 57, binary 111001, from binary to octal, from the right of the binary to the left 3 digits of a group, the front is not enough to fill 0, that is, 111,001, the calculation octal is 071;
Converted from binary to 16 binary, from the right of the binary to the left 4 digits of a group, the front is not enough to fill 0, that is, 0011,1001, the calculation of hexadecimal for 0x39;
3. Comments
Single-line Comment
/**/Multi-line comments
4. Basic data type
Commonly used are 3, char, int, float, respectively 1 characters, 4 characters, 4 or 8 characters; placeholder%c,%d,%f
5, variable, represents a storage area
Type modifier type name = initial value
6. Naming rules for variable names
Can only be made up of numbers, letters, and underscores, and numbers cannot begin
Cannot have the same name as a system reserved word
Cannot make a duplicate variable name.
See the name and the meaning (specification)
Hump nomenclature: The first letter is lowercase and the remaining initials are capitalized. such as: Studentage
7. Note: The return value of an expression
8. The statement is the smallest unit of program execution, ending with a semicolon
9, input, output statement
scanf if the reading data item type matches the format character, continue reading?; Otherwise, you are no longer viewing the remainder, which returns
Printf
10. Escape character
\ n Escape character
\ \ print \ printf ("\ \ \ n");
Percent Print% printf ("%%\n"); Output%
C language 01