Back

Shubham

Fearless • 21d

🚀 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... • 2m

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

Shubham

Fearless • 11d

Day 10/21 – JavaScript: Callback, Promise & Async/Await Today I learned how JavaScript handles asynchronous tasks like API calls, file loading, or timers. ⚡ 🔹 Callback – a function passed into another function function fetchData(cb) { setTimeou

See More
Reply
1

Shubham

Fearless • 18d

Day 05/21 – JavaScript Functions & Methods Today I explored one of the most powerful concepts in JavaScript: Functions & Methods. 🚀 🔹 Functions are blocks of code designed to perform a specific task. They help in reusability and make code cleaner

See More
Reply
1

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

Shubham

Fearless • 2d

Day 11/21 – JavaScript API Calls 🌐 Today I explored how to fetch data from APIs in JavaScript using async/await. Copy code Javascript async function getUsers() { try { let response = await fetch("https://jsonplaceholder.typicode.com/users");

See More
Reply
2

Vagle

Hakuna matata • 4m

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

Shubham

Fearless • 12d

Day 09/21 – JavaScript Classes & Objects Today I explored Classes & Objects in JavaScript – the building blocks of Object-Oriented Programming (OOP). 🚀 🔹 Objects = collections of data & methods 🔹 Classes = blueprints to create objects Example:

See More
Reply
8

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