Declaration method of the variable: 1, the first declaration after the assignment int A;
A=3;
2, the definition variable is directly assigned the value int a=3;
3, you can declare multiple variables of the same type at once, separated by commas between the multi-variable names, and end with a semicolon
int zsage=18,lsage=20,wwage=30;
The declaration principle of a variable: first declare----after the assignment-----last used. Variable can be repeated assignment (but to a variable to assign a new value, then the old value in the variable is no longer exist, in the method is generally defined only once, but can be assigned multiple times, the value of the variable will be assigned to overwrite the value)
Naming rules for variables: 1, cannot start with a number 2, cannot repeat with keywords in C # 3, the same variable name cannot be defined repeatedly 4, case sensitive (camel named first word letter lowercase after each word initials capitalized in English words)
Declaring methods, principles, and naming conventions for variables