Class Central is learner-supported. When you buy through links on our site, we may earn an affiliate commission.

freeCodeCamp

JavaScript Interview Prep: Functions, Closures, Currying

via freeCodeCamp

Overview

Save Big on Coursera Plus. 7,000+ courses at $160 off. Limited Time Only!
Prepare for JavaScript interviews by mastering functions, closures, and currying in this comprehensive tutorial. Explore function declarations, expressions, and anonymous functions before diving into advanced concepts like first-class functions, IIFEs, and closures. Learn about function scopes, hoisting, and the differences between parameters and arguments. Understand callback functions, arrow functions, and their distinctions from normal functions. Delve into lexical scope, closure examples, and their practical applications. Tackle various interview questions, including time optimization, private counters, and module patterns. Finally, master currying techniques, infinite currying, and DOM manipulation using curried functions. Enhance your JavaScript skills and boost your interview readiness with hands-on examples and in-depth explanations.

Syllabus

⌨️ Intro
⌨️ Function Declaration
⌨️ Function Expression
⌨️ Anonymous Function
⌨️ First Class Functions
⌨️ What is IIFE?
⌨️ IIFE - Interview Question
⌨️ Closures
⌨️ Function Scopes
⌨️ Function Scope - Interview Question
⌨️ Hoisting in Functions
⌨️ Hoisting - Interview Question
⌨️ Params vs Arguments
⌨️ Spread vs Rest Operators
⌨️ Interview Question on params, args, spread, rest
⌨️ Callback Function
⌨️ Callback Function - Interview Questions
⌨️ Arrow Functions
⌨️ Arrow function vs Normal Function
⌨️ Closures
⌨️ What is Lexical Scope?
⌨️ Lexical Scope - Interview Question
⌨️ What is Closure?
⌨️ Example of Closures
⌨️ Why Closure?
⌨️ Closure Scope Chain
⌨️ Ques 1 - What will it print?
⌨️ Ques 2 - Write a function for this
⌨️ Ques 3 - Time Optimisation with Closures
⌨️ Ques 4 - setTimeout + block scope with Closures
⌨️ Ques 5 - Create a private counter
⌨️ Ques 6 - What is Module Pattern?
⌨️ Ques 7 - Make this run only once
⌨️ Ques 8 - Once Polyfill Implementation
⌨️ Ques 9 - Memoise/Caching Implementation
⌨️ Ques 10 - Closure vs Scope
⌨️ Currying
⌨️ What is Curring in Javascript?
⌨️ Example of Currying
⌨️ Ques 1 - Implement sum261
⌨️ Ques 2 - Reusing Variable for logic
⌨️ Ques 3 - Infinite Currying
⌨️ Ques 4 - Currying vs Partial Application
⌨️ Ques 5 - Manipulating DOM
⌨️ Ques 6 - curry implementation

Taught by

freeCodeCamp.org

Reviews

Start your review of JavaScript Interview Prep: Functions, Closures, Currying

Never Stop Learning.

Get personalized course recommendations, track subjects and courses with reminders, and more.

Someone learning on their laptop while sitting on the floor.