If Statements (Cont)
Lesson 17Author : 🦒
Last Updated : October, 2017
Code
var isStudent = false;
var isSmart = false;
if(isStudent && isSmart){
document.write("You are a student");
} else if(isStudent && !isSmart){
document.write("You are not a smart student");
} else {
document.write("You are not a student and not smart");
}
document.write("<br>");
// >, <, >=, <=, !=, ==
if(1 > 3){
document.write("number comparison was true");
}
document.write("<br>");
if("dog" != "dog"){
document.write("string comparison was true");
}