Tag

#code

29articles
BasicsOct 13, 2026

What is a sparse array — and why map won't fill Array(3)

What a sparse array is, in plain words: holes instead of elements. Why Array(3).map does nothing, and why the array's length lies to you.

5 min read
BasicsOct 8, 2026

What is a higher-order function — and why map(parseInt) breaks your numbers

A higher-order function, explained simply: a function that takes or returns another function. Why map(parseInt) gives NaN and how to read this kind of code.

5 min read
BasicsOct 1, 2026

What is a graph in programming — and why walking one can hang forever

What a graph is in programming, in plain words: points and the links between them. Where graphs hide in apps and maps, and why a graph walk can loop forever.

5 min read
BasicsOct 1, 2026

What are getters and setters — and why a field vanishes when you send it to the server

What a getter and a setter are, in plain words: a property that looks like a field but actually runs code. And why JSON.stringify quietly drops it.

5 min read
BasicsOct 1, 2026

What is a generic — and why any in AI-written code kills your autocomplete

What a generic is in TypeScript, in plain words: a function that remembers the type of what you gave it. Why it beats any, and where you've already seen one.

5 min read
BasicsSep 30, 2026

What is an enum — and why JavaScript doesn't have one and TypeScript is moving away from it

What an enum is, in plain words: a closed list of allowed values. The bug it catches, why JavaScript has no enum, and what to write instead of enum in TypeScript.

5 min read
BasicsSep 30, 2026

What is a stack in programming — and why Ctrl+Z works the way it does

What a stack is, in plain words: a pile where the last thing in is the first thing out. How Ctrl+Z, the Back button and the call stack in your code are built on it.

5 min read
BasicsSep 30, 2026

interface vs type in TypeScript — which to pick, and why two interfaces silently merge

interface vs type in TypeScript: what the difference is and which one a beginner should pick. A criteria breakdown, the official docs' rule of thumb, and the interface merging trap.

5 min read
BasicsSep 26, 2026

What is a data type — and why JavaScript thinks null is an object

What is a data type, in plain words: a label that tells a program how to read a value. The main types, how to check them, and where the bugs come from.

5 min read
BasicsSep 26, 2026

What is a code comment — and why AI writes them wrong

What is a comment in code, in plain words: a margin note the program skips. How to write one, why 'why' beats 'what', and how to steer AI with comments.

5 min read
GuidesSep 26, 2026

How to format code automatically — and why it matters when AI writes it

How to set up automatic code formatting with Prettier in 10 minutes: install, format on save, and a rule for your AI agent. Step by step.

6 min read
BasicsSep 25, 2026

What is an if statement in programming — and why branch order decides everything

What an if statement is, in plain words: a fork in the code, “if — else”. Why code checks branches top to bottom and how one wrong order breaks discounts.

5 min read
BasicsSep 25, 2026

What is a file path — and why it works on your computer but not on the server

What a file path is, in plain words: a file's address on disk. How an absolute path differs from a relative one, and what ./ and ../ mean in code.

5 min read
BasicsSep 25, 2026

What is a class in programming — the blueprint code uses to stamp out objects

What a class is in programming, in plain words: a blueprint for objects. How a class differs from an object, what new does, and why AI writes classes.

5 min read
BasicsSep 25, 2026

Function vs method — what's the difference, and why it isn't about how they're written

Function vs method: the difference in plain words. Why Python uses len(x) and not x.len(), what this gives a method, and when to write each one.

5 min read
BasicsSep 24, 2026

What is a string in programming — and why "5" and 5 aren't the same

What a string is, in plain words: text in quotes. Why "2" + "2" gives "22", an emoji counts as two characters, and everything from a form arrives as a string.

5 min read
BasicsSep 23, 2026

What is scope in programming — and why a variable is "not defined" when it's right there

What scope is in programming, in plain words: where in code a variable exists and where it doesn't. Why is not defined happens and how to read curly braces.

5 min read
BasicsSep 23, 2026

What is null — and why its inventor called it a billion-dollar mistake

What null means in programming, in plain words: "deliberately empty." How null differs from undefined, where Cannot read properties of null comes from, and how to avoid it.

5 min read
BasicsSep 23, 2026

What is an object in programming — and why two identical objects aren't equal

What an object in programming is, in plain words: a card with labeled fields. How it works, where it shows up in AI-written code, and why {a:1} isn't {a:1}.

5 min read
BasicsSep 23, 2026

let vs const — which to use, and why AI writes const almost everywhere

let vs const in JavaScript: what the difference is and which to pick. A criteria breakdown, a one-second rule, and why const doesn't mean "can't change."

5 min read
BasicsSep 22, 2026

What is an array — and why it counts from zero

What is an array in plain words: a list that keeps its order. Why counting starts at zero, where the most common beginner bug comes from, and why an empty array matters.

5 min read
BasicsSep 22, 2026

What is a loop — and why it can run zero times

What is a loop in programming, in plain words: repeat one action for every item in a list. Why you almost never know the number of repeats in advance.

5 min read
BasicsSep 22, 2026

What is a callback — and why extra parentheses break your button

What is a callback in plain words: a function you hand over instead of calling. Why it works that way, where you've already written one, and which parentheses break everything.

5 min read
BasicsSep 19, 2026

What is a variable — and why a copy of a list changes together with the original

A variable isn't a box holding a value — it's a tag attached to one. That's the bug every beginner hits: you edit the copy of a list and break the original.

5 min read
BasicsAug 14, 2026

What is a function in programming — and why AI breaks code without them

A function isn't a way to save lines. Here's what a function is in plain words, how it's built, and why it decides whether AI can fix your code or wreck it.

5 min read
BasicsAug 13, 2026

What is recursion — a function that calls itself (and where its floor is)

Recursion is a function calling itself. What recursion is in plain words, why the base case is mandatory, and where that stack overflow error comes from.

5 min read
Vibe codingAug 2, 2026

Red flags in AI-generated code — 7 things to check before you ship

AI code breaks where things are boring, not where they're hard. Seven places worth a look before your users find them for you.

6 min read
BasicsJul 20, 2026

What is refactoring — why change code that already works

What is refactoring in plain words: editing code so that nothing changes on the outside. Why touch working code at all, and how to ask AI to do it safely.

5 min read
GuidesJul 4, 2026

How to give AI context about your code — so it stops guessing

AI writes off-target because it can't see your project. Here's a step-by-step way to give AI context about your code with a single file — so answers get accurate.

6 min read