JavaScript
const
Declares a block-scoped binding that cannot be reassigned.
Programming language reference
Look up reserved words and common language tokens, with a clear explanation of what each one does.
JavaScript
constDeclares a block-scoped binding that cannot be reassigned.
JavaScript
letDeclares a block-scoped variable that can be reassigned.
JavaScript
varDeclares a function-scoped variable; avoid it in new code because its scope and hoisting can surprise.
JavaScript
functionDeclares a function that can be called to run reusable code.
JavaScript
returnEnds a function and optionally sends a value back to its caller.
JavaScript
asyncMarks a function so it returns a Promise and can use await.
JavaScript
awaitWaits for a Promise to settle inside an async function or module.
JavaScript
classDeclares a class used to create objects and define methods.
JavaScript
extendsCreates a class that inherits from another class.
JavaScript
newCreates an instance from a constructor or class.
JavaScript
thisRefers to the current call context; its value depends on how a function is called.
JavaScript
superCalls or accesses the parent class constructor and methods.
JavaScript
importBrings exported values from another module into this module.
JavaScript
exportMakes values available for other modules to import.
JavaScript
tryStarts a block whose thrown errors can be handled.
JavaScript
catchHandles an error thrown from a matching try block.
JavaScript
finallyRuns cleanup code after try/catch, whether or not an error occurred.
JavaScript
throwRaises an exception that interrupts normal execution.
JavaScript
typeofReturns a string describing the type of a value.
JavaScript
instanceofChecks whether an object inherits from a constructor's prototype.
JavaScript
forStarts a loop that repeats while its condition or iterator rules allow.
JavaScript
ofIterates over values from an iterable, commonly in a for...of loop.
JavaScript
inChecks property membership or iterates over enumerable object keys.
JavaScript
ifRuns a block only when its condition is truthy.
JavaScript
elseProvides the alternative branch when an if condition is false.
JavaScript
switchSelects a branch by comparing an expression with case values.
JavaScript
breakExits the nearest loop or switch statement.
JavaScript
continueSkips to the next iteration of the nearest loop.
JavaScript
deleteRemoves an object's own property.
JavaScript
voidEvaluates an expression and returns undefined; often seen in older code.
Python
defDefines a function.
Python
classDefines a class, a blueprint for creating objects.
Python
returnEnds a function and optionally returns a value.
Python
ifRuns a block when a condition is true.
Python
elifChecks another condition when earlier if/elif conditions were false.
Python
elseRuns the fallback branch when preceding conditions are false.
Python
forIterates over items from an iterable.
Python
whileRepeats a block while a condition remains true.
Python
breakExits the nearest loop immediately.
Python
continueSkips the rest of the current loop iteration.
Python
tryStarts a block where exceptions can be handled.
Python
exceptCatches matching exceptions raised in a try block.
Python
finallyRuns cleanup code whether an exception occurred or not.
Python
raiseRaises an exception.
Python
withRuns a block within a context manager, which handles setup and cleanup.
Python
asAssigns an alias, such as a context manager target or imported name.
Python
importLoads a module or names from a module.
Python
fromSpecifies the module from which names are imported.
Python
lambdaCreates a small anonymous function expression.
Python
yieldProduces a value from a generator while preserving its execution state.
Python
asyncDefines an asynchronous function or context.
Python
awaitSuspends an async function until an awaitable completes.
Python
passDoes nothing; used as a placeholder where a statement is required.
Python
assertRaises AssertionError if a condition is false; useful for checks during development.
Python
delRemoves a name, item, or object attribute binding.
Python
globalDeclares that assignments in a function refer to a module-level name.
Python
nonlocalDeclares that assignments refer to a name in an enclosing function scope.
Python
inTests membership or appears in iteration syntax.
Python
isChecks whether two references point to the same object.
Python
andReturns a truthy/falsy operand based on whether both conditions are true.
Python
orReturns a truthy/falsy operand based on whether either condition is true.
Python
notNegates a truth value.
Python
NoneThe singleton value representing the absence of a value.
Python
TrueThe Boolean value for true.
Python
FalseThe Boolean value for false.
TypeScript
interfaceDefines the expected shape of an object or class contract.
TypeScript
typeCreates a name for a type, including unions, intersections, and object shapes.
TypeScript
enumDefines a named set of related constant values.
TypeScript
implementsDeclares that a class satisfies a specified interface.
TypeScript
extendsInherits from a class or builds a type from another type.
TypeScript
readonlyPrevents reassignment of a property or array elements through that reference.
TypeScript
keyofProduces a union of the property names of a type.
TypeScript
typeofGets a value's type in JavaScript or refers to a variable's type in TypeScript type positions.
TypeScript
asAsserts a type to the compiler or renames an import/export.
TypeScript
declareTells TypeScript that a value exists elsewhere, without emitting its implementation.
TypeScript
publicAllows a class member to be accessed from anywhere.
TypeScript
privateRestricts a class member to its declaring class.
TypeScript
protectedAllows access in the declaring class and its subclasses.
TypeScript
abstractMarks a class or method as a base definition that must be completed by subclasses.
TypeScript
neverThe type for values that never occur, such as a function that always throws.
TypeScript
unknownA safe top type; values must be narrowed before use.
TypeScript
anyDisables type checking for a value; use sparingly because it removes safety.
TypeScript
inferIntroduces a type variable inside a conditional type for pattern matching.
TypeScript
satisfiesChecks that a value conforms to a type while preserving its more specific inferred type.
TypeScript
assertsMarks a function as narrowing a condition or variable after it returns.
Java
classDeclares a class that defines object state and behavior.
Java
interfaceDeclares a contract that implementing classes must fulfill.
Java
extendsInherits from a class or, for interfaces, another interface.
Java
implementsDeclares that a class provides the methods required by an interface.
Java
newCreates an object or array instance.
Java
thisRefers to the current object instance.
Java
superRefers to the parent class, often to call its constructor or methods.
Java
staticMakes a member belong to the class rather than an instance.
Java
finalPrevents reassignment of a variable, overriding of a method, or subclassing of a class.
Java
voidDeclares that a method does not return a value.
Java
returnEnds a method and optionally provides its result.
Java
ifRuns a statement when a condition is true.
Java
elseProvides an alternative branch for an if statement.
Java
switchSelects a branch based on a value.
Java
forRepeats statements using a loop counter or iterable.
Java
whileRepeats statements while a condition is true.
Java
tryStarts a block where exceptions may be caught or resources managed.
Java
catchHandles a matching exception from a try block.
Java
throwThrows an exception explicitly.
Java
throwsDeclares exceptions that a method may pass to its caller.
Java
privateLimits access to the declaring class.
Java
protectedAllows access within the package and by subclasses.
Java
publicAllows access from any class that can reach the type.
Java
packageDeclares the package that contains a source file.
Java
importMakes types from other packages available by their simple names.
Java
instanceofTests whether an object is an instance of a type.
Java
abstractMarks an incomplete class or method intended for subclass implementation.
Java
enumDeclares a fixed set of named constants.
Java
synchronizedCoordinates access to a block or method using an object's monitor.
Java
volatileEnsures reads and writes to a field are visible across threads.
C++
classDeclares a class type with data and member functions.
C++
structDeclares a class-like type whose members are public by default.
C++
namespaceGroups names to avoid collisions and organize code.
C++
templateDefines generic functions or types parameterized by compile-time values or types.
C++
typenameIdentifies a dependent name as a type in a template.
C++
autoAsks the compiler to infer a variable's type from its initializer.
C++
decltypeProduces the declared type of an expression.
C++
constexprMarks values or functions that can be evaluated at compile time when possible.
C++
constPrevents modification through a particular variable or reference.
C++
staticGives a name static storage duration or limits a file-scope name to its translation unit.
C++
virtualEnables runtime method dispatch through a base class interface.
C++
overrideConfirms that a method overrides a virtual base method.
C++
publicMakes class members accessible to any caller.
C++
privateRestricts class members to the declaring class and its friends.
C++
protectedAllows access in the class, its derived classes, and friends.
C++
newAllocates an object dynamically and initializes it.
C++
deleteDestroys and deallocates an object created with new.
C++
tryStarts a block where thrown exceptions can be caught.
C++
catchHandles exceptions of a matching type.
C++
throwRaises an exception.
C++
returnEnds a function and optionally returns a value.
C++
nullptrThe null pointer literal introduced in modern C++.
C++
thisPoints to the object on which a non-static member function was called.
C++
usingIntroduces a name or type alias into scope.
C++
enumDeclares a set of named values; enum class provides scoped enumerators.
Go
packageDeclares the package a source file belongs to.
Go
importMakes another package available to the current file.
Go
funcDeclares a function or method.
Go
varDeclares a variable with an explicit or inferred type.
Go
constDeclares a compile-time constant.
Go
typeDefines a new named type or type alias.
Go
structDeclares a composite type that groups fields.
Go
interfaceDefines a set of methods; types satisfy it implicitly by implementing them.
Go
mapBuilt-in keyword for declaring map types, such as map[string]int.
Go
chanDeclares a channel type for communication between goroutines.
Go
goStarts a function call in a new goroutine.
Go
deferSchedules a function call to run when the surrounding function returns.
Go
selectWaits on multiple channel operations and runs one that is ready.
Go
ifRuns a block when a condition evaluates to true.
Go
elseProvides an alternative branch to an if statement.
Go
forThe only loop keyword; supports traditional, condition-only, and range forms.
Go
rangeIterates over elements in arrays, slices, maps, strings, or channels.
Go
switchSelects a matching case; Go switches do not fall through by default.
Go
caseDefines a branch in a switch or select statement.
Go
defaultDefines the fallback branch in a switch or select statement.
Go
returnEnds a function and returns zero or more values.
Go
breakExits the innermost loop or switch, or a labeled statement.
Go
continueSkips to the next iteration of the innermost loop.
Go
fallthroughContinues execution into the next case in a Go expression switch.
Go
panicStops normal flow and begins panic unwinding.
Go
recoverRegains control from a panic inside a deferred function.
Rust
fnDeclares a function.
Rust
letBinds a name to a value; bindings are immutable unless declared mut.
Rust
mutMakes a binding or reference mutable.
Rust
structDefines a custom data type with named fields.
Rust
enumDefines a type with a set of possible variants.
Rust
implDefines methods or trait implementations for a type.
Rust
traitDefines shared behavior that types can implement.
Rust
pubMakes an item visible outside its current module, subject to visibility rules.
Rust
useBrings a path into scope or declares a re-export.
Rust
modDeclares a module, organizing code and controlling visibility.
Rust
matchSelects behavior by exhaustively matching a value's pattern.
Rust
ifRuns a block when a Boolean condition is true; it can also produce a value.
Rust
loopRepeats a block indefinitely until it exits with break.
Rust
whileRepeats a block while a condition remains true.
Rust
forIterates over values from an iterator.
Rust
moveMoves captured values into a closure or transfers ownership.
Rust
asyncDefines an asynchronous block or function that produces a Future.
Rust
awaitWaits for a Future to complete inside an async context.
Rust
whereAdds constraints to generic type parameters.
Rust
typeDefines a type alias or associated type.
Rust
constDeclares a compile-time constant.
Rust
staticDeclares a value with a fixed memory location and static lifetime.
Rust
unsafeMarks code that may perform operations the compiler cannot fully verify.
Rust
returnReturns a value from a function, though Rust often uses a final expression instead.
Rust
loopCreates an unconditional loop; its break can return a value.
SQL
SELECTChooses columns or expressions to return from a query.
SQL
FROMSpecifies the table or data source to read.
SQL
WHEREFilters rows before grouping or aggregation.
SQL
JOINCombines rows from tables using a related condition.
SQL
LEFT JOINReturns all rows from the left table and matching rows from the right.
SQL
GROUP BYGroups rows so aggregate functions can calculate one result per group.
SQL
HAVINGFilters grouped results, usually after aggregation.
SQL
ORDER BYSorts the result set by one or more expressions.
SQL
INSERTAdds new rows to a table.
SQL
UPDATEChanges values in existing rows.
SQL
DELETERemoves rows from a table.
SQL
CREATECreates a database object such as a table, view, or index.
SQL
ALTERChanges the structure of an existing database object.
SQL
DROPRemoves a database object.
SQL
PRIMARY KEYConstrains a column or set of columns to uniquely identify each row.
SQL
FOREIGN KEYConstrains values to reference a key in another or the same table.
SQL
UNIQUEPrevents duplicate values in a column or column combination.
SQL
NOT NULLRequires a column to have a value rather than NULL.
SQL
NULLRepresents missing or unknown data; comparisons use IS NULL, not = NULL.
SQL
DISTINCTRemoves duplicate rows from the selected result.
SQL
UNIONCombines query results and removes duplicates; UNION ALL keeps them.
SQL
WITHDefines a common table expression (CTE) for use by a query.
SQL
CASEEvaluates conditions and returns a value for the first matching branch.
SQL
COMMITMakes the current transaction's changes permanent.
SQL
ROLLBACKCancels changes made in the current transaction.
SQL
BEGINStarts a transaction in many SQL database systems.
SQL
INDEXA database structure that can speed up lookups at the cost of storage and writes.