Basic LevelFUNDAMENTALS · JavaScript TrackCompiler: node 20.x (V8 Engine)
JavaScript Basic Fundamentals & Control Flow
Console output, variables (let/const), expressions, conditionals, and iteration.
Exercises:5 Practice Labs
All JavaScript ModulesBasic Coding Labs (5)Click any card to start in laboratory
Lab #01 · Basic Syntax
Easy5 mins
01. Console Output & Primitive Variables
Declare variables and log formatted output to the console.
Objective: Declare `lang = 'JavaScript'` and `version = 'ES2024'`. Print: `[*] Active Engine: JavaScript vES2024`.
Interactive SandboxStart Lab
Lab #02 · Operators & Expressions
Easy6 mins
02. Arithmetic, Nullish Coalescing & Default Values
Handle fallback default values using `??` nullish coalescing operator.
Objective: Write a function `getPort(configured)` that returns `configured ?? 8080`.
Interactive SandboxStart Lab
Lab #03 · Control Flow
Easy8 mins
03. Conditionals & Type Inspection (typeof)
Inspect runtime types using `typeof` and conditionals.
Objective: Write a function `formatMetric(val)` that returns `val.toFixed(2)` if number, or `val.toUpperCase()` if string.
Interactive SandboxStart Lab
Lab #04 · Loops & Iteration
Easy10 mins
04. For-Of, While Loops & Accumulators
Iterate across arrays using `for...of` loops and accumulate totals.
Objective: Write a function `calculateTotalBytes(packetSizes)` using a `for...of` loop.
Interactive SandboxStart Lab
Lab #05 · Nested Loops
Easy10 mins
05. Nested Loops & 2D Matrix Transforms
Flatten and transform 2D matrix arrays with nested loops.
Objective: Write a function `flatten2D(matrix)` that flattens a 2D array into a 1D array using nested loops.
Interactive SandboxStart Lab