Hi Guys,
I’m trying to get the text “eyooo” and the text “between 10 and 100” to appear in my chrome browser page, but instead I always get a blank page. I made a small if-else condition in ATOM.
Do I have to install something to get the script tag to work?
Hello world <script>
var displayText ("eyooo");
document.write("<h1>" + displayText + "</h1>");
var a = 5;
var b = 10;
var c = 17;
var d = a + b + c;
if (d > 100) {
document.write("<h1> bigger than 100 </h1>");
} elseif (100 > d > 10){
document.write("<h2> between 10 en 100 </h2>");
}
else {
document.write("<h3> smaller than 10 </h3>");
}
</script>