* (Asterisk) is ASCII code point 42 (0x2A), Unicode U+002A, and a printable punctuation character. It marks a footnote or signals omission — in everyday writing it's the typographic wink that says "see below for the fine print." Programming gives the asterisk a staggering range of duties. It's the multiplication operator in virtually every language, the wildcard in shell globs (*.txt) and SQL (SELECT *), and the critical dereferencing operator in C and C++ where *ptr follows a pointer to the value it addresses. Python packs and unpacks arguments with it: *args collects positional parameters, **kwargs collects keyword pairs. In regular expressions, * means "zero or more of the preceding element," making it a Kleene star borrowed from formal language theory. Markdown uses it for emphasis and list items. With so many meanings, the trap is almost inevitable in C: confusing precedence between * and -> when navigating nested structures, or declaring int* a, b and assuming both variables are pointers when only a is — the * binds to the variable name, not the type, no matter how you space it. The glyph dates to at least the second century, where scribes used a star-shaped mark in margins to flag important passages in manuscripts. UTF-8 encodes it as a single byte 0x2A. Unicode classifies it as Po (Punctuation, Other) with the name ASTERISK. The visually similar heavy asterisk ✱ (U+2731) and the six-pointed asterisk ✻ (U+273B) live in the Dingbats block and occasionally sneak into documents via autocorrect.
int x = 21;int y = x * 2; // '*' multiplicationint *p = &x; // address-ofint v = *p; // '*' dereference
The asterisk is one of the most overloaded characters in computing. It's multiplication (3 * 4), pointer dereference in C (*ptr), glob wildcard (*.txt), regex quantifier ('zero or more'), CSS selector (*, *::before), SQL wildcard (SELECT *), and Markdown bold (**text**). Context determines everything.
In shell globbing, * matches any sequence of characters in a filename (*.txt matches all .txt files). In regex, * means 'zero or more of the preceding element' — a* matches '', 'a', 'aaa'. The glob * is equivalent to regex .* — a common source of confusion.
In Python, ** is exponentiation (2**10 = 1024) and dictionary unpacking (**kwargs). In JavaScript/TypeScript, ** is exponentiation (2**10). In glob patterns, ** matches any directory depth (src/**/*.ts). In Markdown, **text** makes text bold.
SELECT * fetches all columns, which wastes bandwidth, prevents the optimizer from using covering indexes, breaks if columns are added/renamed, and obscures which data your code actually needs. Explicit column lists (SELECT id, name) are faster, clearer, and more maintainable.