#8 JavaScript if..else | JavaScript for Beginners

preview_player
Показать описание
An if else statement in programming is a conditional statement that runs a different set of statements depending on whether an expression is true or false.

In this video, we will learn about if/else statements to perform different actions under different conditions. If the condition is true, we will do one set of tasks, and if the condition is false we will do another set of tasks. This is called decision-making in programming.
We will see how we can implement decision-making in JavaScript.

~

Timestamps:
00:33 JavaScript if Statement
04:18 if...else Statement
06:05 else if Statement
10:38 Programming Task
11:30 Programiz Quiz

Find Programiz elsewhere:

---------------------------------------------------

#8 JavaScript if...else | JavaScript for Beginners

#programiz #javascript #ifelse #learnprogramming #ifelsestatement #js
Рекомендации по теме
Комментарии
Автор

🚀Loved the JS tutorial? Take it further with Programiz PRO!
Refine your skills and build confidence with interactive lessons, quizzes, and challenges. Strengthen your programming foundation and master JavaScript today!

programizstudios
Автор

Video Quiz:

Q. What is the output of the following code?

const time = 15;
if (time < 10)
console.log("Good Morning");
else if (time < 19)
console.log("Good Evening");
else if (time < 22)
console.log("Good Night");
else
console.log("Invalid Time");

1. Good Morning
2. Good Evening
3. Good Night
4. Invalid Time

programizstudios
Автор

The course is absolutely fantastic i was loving it but its confusing you say the course is free but at one point it says buy to continue with 7 days free trial....Can you please elaborate i simply dont get it...do i jave to pay after 7 days or i can cancel it if i didnt like it after 7 days

saurabhrajput
Автор

Pls Make videos construction in js 🙇‍♂️

sameeraj
Автор

In your online javascript compiler it throws an internal error while we run prompt


Can you check please

basheerahmedk
Автор

"use strict"

const ps = require("prompt-sync")
const prompt = ps()

const number = parseInt(prompt("Enter number here!: "))

if (number > 0) {
console.log("Number is positive")
}

else if (number < 0) {
console.log("Number is negative")
}

else {
console.log("number is 0")
}

KINGSNEEDTHETERRIBLE
Автор

I nowhere found my issue solve which I wanted to know. And I wondered to know how to represent most large number among 10 numbers using only “if else”

sinistersinister
Автор

const digit = parseFloat (prompt("Enter your Number"));

if (digit > 0 ){
console.log("Your Number is postive");

}

else{
console.log("Your number is Negative");
}

nipunsamantha
join shbcf.ru