Back

Sagar gupta

Full-time Freelancer... • 1y

Most Javascript Questions Asked in Interview | PART 2 1. What is difference between a for loop and for Each loop Ans: A for loop is traditional loop that uses a counter variable to iterate over an array. ForEach loop is a method that iterate over an array and execute a callback function for each element.forEach loop is more concise but it can be slower and less flexible than traditional for loop. 2. How does javascript handle asynchronous programming. Ans: javascript uses callback to handle asynchronous programming , javascript also support promises and async await syntax which provides more concise and readable way of handling asynchronous code. 3.what is callback function. Ans: Callback is a function that is passed as an argument to another function and is executed when a specific operation is completed.

Reply
3
10

More like this

Recommendations from Medial

Shubham

Fearless • 4d

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

Prince Singh Chouhan

Front-end Developer • 1y

#Array in #javascript: Array in Javascript enables storing a collection of multiple items under a single variable name, and has members for performing common array operations. Arrays aren't primitives but are instead Array #objects with the followin

See More
Reply
2

sai akhilesh

Student @Geethanjali... • 1y

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

Reply
3

Shubham

Fearless • 11d

🚀 Day 4/21 – My JavaScript Learning Journey Today’s focus: Arrays in JavaScript 📦 An Array is a special object in JS used to store multiple values in a single variable. 🔹 Creating Arrays let fruits = ["Apple", "Banana", "Mango"]; 🔹 Common Me

See More
Reply
3
Image Description
Image Description

Rohit Gupta

Aspiring Web Develop... • 1y

Day30 of 100daysofcodechallenge... Today I learned about Object Literal, Array of object and Math object In JavaScript. I also make a basic "Guess The Number" game.

5 Replies
8

Rohit Gupta

Aspiring Web Develop... • 1y

Day30 of 100daysofcodechallenge... Today I learned about Object Literal, Array of object and Math object In JavaScript. I also make a basic "Guess The Number" game.

Reply
4

Hari Krishna

Developer | entrepre... • 22d

Day 5/100 : For loop is interesting to work because if we know the range of something has to be executed we can use for loop 🔁 • used range function with for loop to generate password generator 🤖🤖 Github:

Reply
1

Shubham

Fearless • 12d

🚀 Day 3/21 – My JavaScript Learning Journey Today I explored two core concepts: Loops & Strings. 🔹 Loops in JavaScript for → classic loop with index. while → runs until a condition is true. do...while → executes at least once. for...of → best

See More
Reply
2
Image Description

Sagar gupta

Full-time Freelancer... • 1y

Javascript Questions Asked in Every Interview | PART 1 1. What is the difference between Null and undefined. Ans: Null and undefined are both primitive values in javascript that represents the absence of value. Key difference null is deliberately a

See More
1 Reply
2
15

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