Skip to main content
InterviewHubPRO
Section Overview
Q335

Question 335 of 536

Part 6: Async Internals, Memory, Microtasks & Web APIs (329 - 403)

63%
JavaScript & V8 Internals (536 Qs)•Part 6: Async Internals, Memory, Microtasks & Web APIs (329 - 403)

What paradigm is Javascript

senior LevelCode ExampleAsync & PromisesEvent LoopHTTP & REST APIs

JavaScript is a multi-paradigm language, supporting imperative/procedural programming, Object-Oriented Programming and functional programming. JavaScript supports Object-Oriented Programming with prototypical inheritance.

Practical Code Example

javascript
// JavaScript is a Multi-Paradigm Language:
// 1. Prototype-based Object-Oriented Programming (OOP)
class User { constructor(name) { this.name = name; } }

// 2. Functional Programming (First-class functions, pure functions, immutability)
const double = x => x * 2;
[1, 2, 3].map(double);

// 3. Event-Driven Asynchronous Programming
setTimeout(() => console.log('Event driven'), 100);