Skip to content

Instantly share code, notes, and snippets.

@firstfu
Created November 29, 2019 05:39
Show Gist options
  • Select an option

  • Save firstfu/b4254e5c82aab01e710d5b49482bc126 to your computer and use it in GitHub Desktop.

Select an option

Save firstfu/b4254e5c82aab01e710d5b49482bc126 to your computer and use it in GitHub Desktop.

Revisions

  1. firstfu created this gist Nov 29, 2019.
    6 changes: 6 additions & 0 deletions Node --NaN.js
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,6 @@
    ## 判断是否为isNaN
    let n1 = NaN
    let n2 = 'NaN'
    console.log(Number.isNaN(n1))
    console.log(Number.isNaN(n2))