Skip to content

otherV/B13-A5

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

1️⃣ What is the difference between var, let, and const?

  • var: Function-scoped, value can be changed, hoisting possible.
  • let: Block-scoped, value can be changed.
  • const: Block-scoped, cannot be reassigned to new value.

2️⃣ What is the spread operator (...)?

Used for spreading/unpacking an array. Example, [...issueArray, newIssue] creates a new list. Can be used to merge multiple arrays to a new one.


3️⃣ What is the difference between map(), filter(), and forEach()?

  • map(): Creates a new array of same length, every item of the given array can be transformed as needed using map().
  • filter(): Gives a new array filtered out from a given array according to some condition.
  • forEach(): Does something for every item of a given array, no returns.

4️⃣ What is an arrow function?

A compact way to write functions using => syntax.


5️⃣ What are template literals?

Surrounding strings in backticks (``), not quotes- are template literals. Mostly used for easier handling of long strings.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors