1: js supports Unicode character set, so you can name functions in Chinese.
Two: js has no initialized variables in Var, the default is undefined
Third: For variables that are neither declared nor assigned a value, if used directly, a system-level Error will be thrown. If you use typeof (typeof is a type operator) operation, regardless of whether it has been declared, a string "undefined" will be returned;
Example:
//a Undeclared
alert(typeof(a));//undefined
alert(a);//Error
Four: Arithmetic operators. " " can be used to convert a value into a string more conveniently. The specific operation is to add an empty string to the value (or not write it).
Example:
Var a=2.96;
Var b=1.0;
Alert(a ”” b);//Get the string” 2.961"
Use "-" to convert a string into a numerical value. The specific operation is to subtract a value 0 from this string
Var a="2.96";
alert(a 1);//Get the string "2.961" (force the value into a string)
alert(a-0 1);//Get the value 3.96
The following is an example I made: