English is Easy!!

আজ থেকেই আপনার ভাষা শেখার যাত্রা শুরু করুন। আপনি যদি নতুন হন অথবা
আপনার দক্ষতা বাড়াতে চান, আমাদের Interactive Lessons আপনাকে নিয়ে যাবে অন্য একটি Level এ



Let's Learn Vocabularies

আপনি এখনো কোন Lesson Select করেন নাই

একটি Lesson Select করুন।

Frequently Asked Questions

1.The difference between var, let, and const.?

The difference between var,let and const

Var:

  • var is function-scoped, meaning it is accessible throughout the entire function in which it
  • Hoisting: Variables declared with var are hoisted to the top of their scope and initialized with
  • Re-declaration: You can re-declare a var in the same scope without errors.

  • let:

  • Scope: let is block-scoped, meaning it is only accessible inside the block {} where it was declared.
  • Hoisting: Variables declared with let are hoisted but not initialized, so accessing them before declaration results in a ReferenceError.
  • Re-declaration: You cannot re-declare a let variable in the same scope.

  • Const

  • Scope: Like let, const is block-scoped.
  • Hoisting: Also hoisted but not initialized.
  • Re-declaration: You cannot re-declare a const variable in the same scope.
  • 2.The difference between map(), forEach(), and filter().?

    The difference between map, forEach and filter:

    map()

  • Purpose: Transforms each element of an array and returns a new array with the modified values.
  • Returns: A new array with the transformed values.
  • Modifies the original array? ❌ No
  • forEach()

  • Purpose: Loops through an array and executes a function for each element, but does not return a new array.
  • Returns: undefined
  • Modifies the original array? ❌ No (unless modified manually)
  • filter()

  • Purpose: Filters an array based on a condition and returns a new array with only the elements that match the condition.
  • Returns: A new array with the filtered elements.
  • Modifies the original array? ❌ No
  • 3.Explain arrow functions and how they are different from regular functions?

    Arrow functions:

    const multiply = (x, y) => x * y;


    Regular functions

    function add(a, b)
    {
    return a + b;
    }

    4.How JavaScript Promises work?

    A Promise is created with a function that performs an asynchronous operation.
    .then() is used to handle a fulfilled promise.
    .catch() handles errors if the promise is rejected.

    5.How closures work in JavaScript?

    A closure in JavaScript is a function that retains access to its lexical scope even after the outer function has finished executing. This is possible because functions in JavaScript "remember" the scope in which they were created.