Function Section Learning:
+parseint ():
The-parseint () function converts any input value it receives (usually a string) to an integer type output, and returns Nan if the conversion fails.
-parseint ("parameter", second parameter cardinality): No second parameter specified, function will default it to decimal
-If the argument is beginning with 0x, the default is hexadecimal
-If the argument starts with 0, the default is octal
+parsefloat ():
-Converts input values to decimal numbers only
! is discarded when the first exception character is encountered, regardless of whether the remaining part of the string is available
-parsefloat () can also accept data in the form of an exponent, which represents 10 of the negative parties, plus or not representing 10 of the positive several parties
-
+isnan ():
The-nan itself does not have the concept of equivalence, so nan = = = The return of Nan is false
+isfinite ():
-Check whether the input is a number that is neither infinity nor Nan
+encodeuri (), encodeURIComponent (), decodeURI (), decodeURIComponent ()
+eval ():
-Executes the input string as a JS code
+alert ():
-All current code will be paused until the execution window of alert () is closed
+ About ascension: The reference code is as follows:
-var a = 123;
function f () {
alert (a);
var a = 1;
alert (a);
}
f (); /function domain is always better than global domain/
-So the first alert (a) is actually the reality of undefined
+ function identifier notation:
-var f = function () {
return 1;
}
-var f = function MyFunc () {
return 1;
}
-In JS The function is also a kind of data:
-What they contain is the code
-they are executable (or callable)
-var sum = function (A, b) {
return a + B;
}
-var add = sum;
JavaScript function section