Javascript Number Type Question 2

Introduction

What is the output of the following code?


let a = parseInt("Hello!");  
if (isNaN(a)) {
    // This will execute
    console.log("That is not a number!");
} else {
    // This will not execute
    console.log("That IS a number.");
}


That is not a number!



PreviousNext

Related