My Authors
Read all threads
Popular JavaScript Interview Questions with Answers.

JavaScript is most popular language with ample of job opportunities. Here is the list of 20 most asked #javascript interview questions to speed up your preparation.

🧵A Thread 🧵

#100DaysOfCode #Developer
1. What's the difference between undefined and null?

"undefined" is the default value of a variable that has not been assigned a specific value and "null" is a value that represents no value.

#100DaysOfCode #javascript #Developer
2. What does the && operator do?

The && or Logical AND operator finds the first falsy expression in its operands and returns it and if it does not find any falsy expression it returns the last expression.

#100DaysOfCode #javascript #Developer
3. What does the || operator do?

The || or Logical OR operator finds the first truthy expression in its operands and returns it. This too employs short-circuiting to prevent unnecessary work.

#100DaysOfCode #javascript #Developer
4. What is DOM?

DOM stands for Document Object Model is an interface (API) for HTML and XML documents. When the browser first reads our HTML document it creates a big object, a really big object based on the HTML document this is the DOM.

#100DaysOfCode #javascript #Developer
5. What is Event Propagation?

Event propagation is a mechanism that defines how events propagate or travel through the DOM tree to arrive at its target and what happens to it afterward.

#100DaysOfCode #javascript #Developer
6. What's Event Bubbling?

In the Bubbling Phase, the event bubbles up or it goes to its parent, to its grandparents, to its grandparent's parent until it reaches all the way to the window.

#100DaysOfCode #javascript #Developer #techtwitter
7. What's Event Capturing?

In Capturing Phase, the event starts from the window all the way down to the element that triggered the event.

#100DaysOfCode #javascript #Developer
8. What is ?

The is the element on which the event occurred or the element that triggered the event.

#100DaysOfCode #javascript #Developer
9. What's the difference between == and === ?

The difference between ==(abstract equality) and ===(strict equality) is that the == compares by value after coercion and === compares by value and type without coercion.

#100DaysOfCode #javascript #Developer
10. Why does it return false when comparing two similar objects in JavaScript?

#JavaScript compares objects and primitives differently. In primitives, it compares them by value while in objects it compares them by reference or the address in memory where the variable is stored.
11. What does the !! operator do?

The Double NOT operator or !! coerces the value on the right side into a boolean. Basically, it's a fancy way of converting a value into a boolean.

#100DaysOfCode #javascript #Developer
12. How to evaluate multiple expressions in one line?

We can use the , or comma operator to evaluate multiple expressions in one line. It evaluates from left-to-right.

Example -

x = (x++ , x = addFive(x), x *= 2, x -= 5, x += 10);

#100DaysOfCode #javascript #Developer
13. What is Hoisting?

Hoisting is the term used to describe the moving of variables and functions to the top of their (global or function) scope on where we define that variable or function.

#100DaysOfCode #javascript #Developer
14. What is Scope?

Scope in JavaScript is the area where we have valid access to variables or functions.

JavaScript has three types of Scopes -

1. Global Scope
2. Function Scope
3. Block Scope(ES6).
15. What are the falsy values in JavaScript?

falsy values are values that when converted to boolean becomes false.

#100DaysOfCode #javascript #Developer
16. What does "use strict" do?

"use strict" is an ES5 feature in JavaScript that makes our code in Strict Mode in functions or entire scripts. Strict Mode helps us avoid bugs early on in our code and adds restrictions to it.

#100DaysOfCode #javascript #Developer
17. What's the value of this in JavaScript?

"this" refers to the value of the object that is currently executing or invoking the function.

#100DaysOfCode #javascript #Developer
18. What is the prototype of an object?

A prototype in simplest terms is a blueprint of an object. It is used as a fallback for properties and methods if it does exist in the current object. It's the way to share properties and functionality between objects.

19. What are Higher Order Functions?

Higher-Order Function is functions that can return a function or receive argument or arguments which have a value of a function.

#100DaysOfCode #javascript #Developer
20. What's the difference between var, let, and const keywords?

Variables declared with "var" keyword are function scoped. Variables declared with "let" and "const" keyword are block-scoped.
Difference b/w let & const we can assign new values using let but we can't in const
To receive #Coding and #interview tips right on your Inbox consider subscribing to my email list.
(If not already subscribed)

Also, I'm creating a discord group for programmers to help, learn, and share. I will inform you about it too


Allow this list interview question thread reach as many DEVELOPERs as possible by RETWEETING 🔁 it.


Thank you.

#100DaysOfCode #javascript
Missing some Tweet in this thread? You can try to force a refresh.

Keep Current with Mayank - Nlogn🚀

Profile picture

Stay in touch and get notified when new unrolls are available from this author!

Read all threads

This Thread may be Removed Anytime!

Twitter may remove this content at anytime, convert it as a PDF, save and print for later use!

Try unrolling a thread yourself!

how to unroll video

1) Follow Thread Reader App on Twitter so you can easily mention us!

2) Go to a Twitter thread (series of Tweets by the same owner) and mention us with a keyword "unroll" @threadreaderapp unroll

You can practice here first or read more on our help page!

Follow Us on Twitter!

Did Thread Reader help you today?

Support us! We are indie developers!

This site is made by just two indie developers on a laptop doing marketing, support and development! Read more about the story.

Become a Premium Member ($3.00/month or $30.00/year) and get exclusive features!

Become Premium

Too expensive? Make a small donation by buying us coffee ($5) or help with server cost ($10)

Donate via Paypal Become our Patreon

Thank you for your support!