Back

Shubham

Fearlessย โ€ขย 21h

๐Ÿš€ Day 2 of 21 โ€“ JavaScript Learning Journey Topic: Operations & Conditional Statements ๐Ÿ”น Operations in JavaScript Arithmetic: + - * / % Assignment: = += -= Comparison: == === != > < >= <= Logical: && || ! ๐Ÿ”น Conditional Statements // if statement if (age >= 18) { console.log("You can vote!"); } // if...else if (num % 2 === 0) { console.log("Even"); } else { console.log("Odd"); } // if...else if...else if (marks >= 90) { console.log("Grade A"); } else if (marks >= 60) { console.log("Grade B"); } else { console.log("Grade C"); } // switch statement switch(day) { case 1: console.log("Monday"); break; case 2: console.log("Tuesday"); break; default: console.log("Other Day"); } โœจ Key Takeaway: Operations let you calculate & compare, while conditional statements help your code make decisions. ๐Ÿ“Œ Stay tuned for Day 3 โ€“ Loops in JavaScript ๐Ÿ”„ #21DayJavaScript #JavaScript #Coding #LearnToCode

1 Reply
1
16
Replies (1)

More like this

Recommendations from Medial

sai akhilesh

Student @Geethanjali...ย โ€ขย 1y

What is conditional statements in Programming https://youtube.com/shorts/PC3KnjMxKV4?feature=share #javascript #programming #webdevelopment

Reply
3
Image Description
Image Description

Vagle

Hakuna matataย โ€ขย 9m

The perfect if else statement ๐Ÿคฃ

5 Replies
6
Image Description

Sanskar

Keen Learner and Exp...ย โ€ขย 1m

Day 2 of learning python as a beginner. Topic: Conditional Expression Conditional expression pose a condition (if and Else statements). They help program take decision based on the condition given. They can be used inside a function or while assign

See More
4 Replies
4
15

sai akhilesh

Student @Geethanjali...ย โ€ขย 1y

๐ŸŽ‰ The Wait is Over! ๐ŸŽ‰ The video is finally out! ๐Ÿ“ข Watch JavaScript Conditional Statements & Ternary Operator - Full Tutorial & Examples now on Learn With Akhilesh! ๐Ÿš€๐Ÿ“š๐Ÿ’ป Master JavaScript conditionals and the ternary operator with my step-by-s

See More
Reply
3

Vagle

Hakuna matataย โ€ขย 3m

Startup: โ€œWe use AI.โ€ Reality: One if-else statement and a prayer to OpenAI.

Reply
7
Image Description

Rohit Gupta

Aspiring Web Develop...ย โ€ขย 1y

#day29 of #100DaysOfCode #100daysofcodechallenge Today I make TO-DO App using JavaScript. I use while and for loops also if and else if condition.. For adding and deleting from list I use prompt Command.... #Javascript #Connect #Connections #tech

1 Reply
10

Hari Krishna

Developer | entrepre...ย โ€ขย 13d

Today I got to learn some interesting low level stuff like : โ€ข if condition == text ( canโ€™t perform operation bcz not a str ) โŒ โ€ข if condition == โ€œtextโ€ ( can compare bcz itโ€™s a str )โœ… โ€ข power of nested if-else statement ๐Ÿ‘€ Github :

Reply
3
Image Description
Image Description

Shashwat Srivastava

Be free!ย โ€ขย 1y

What Problems do you guys face in use of internet on a day to day basis? This statement is to find out if there is a problem that actually hasn't been solved and we could technically build a product around it!

9 Replies
11
Image Description

Applyly

Hey I am on Medialย โ€ขย 10m

Paytm has launched a UPI statement download Feature By Applyly November 7, 2024 Introduction Paytm has launched a UPI statement download feature to support users in managing expenses and tax filing. This tool is common in developed countries. But Pay

See More
1 Reply
Image Description

Ashish Ahirwar

Aspiring entrepreneu...ย โ€ขย 10m

D-mart is superior. I mean you just can't beat the pricing and if you start shopping for your daily household items you won't go anywhere else the day you enter the store

1 Reply
3

Download the medial app to read full posts, comements and news.