Curly braces: An evolution of UNIX and C 19 May 2026 How were { } curly braces typed with a Teletype Model 33 on UNIX? These characters are especially important for C, but absent on this terminal. I was just asked a similar question and in response, this is a tour of the coevolution of UNIX and C, from this perspective, featuring “hello, world” through the ages. This work is entirely my own (no AI) and the code samples are my construction. Sources for all inferences are cited. ASCII 1963 The Teletype Model 33 famously couldn’t write lowercase letters. This teleprinter was designed around the first edition of the ASCII standard, ASA X3.4-1963, which hadn’t yet decided lowercase was worth adding. Some in the committee thought more control characters would be a better use of the limited encoding space. The standard soon evolved into its modern form, but the Model 33 was the first commercial use of ASCII and wildly popular, so its issues stuck. In addition to missing lowercase, ASCII 1963 and the Model 33 lacked { } curly braces, | vertical bar, ` backtick, and ~ tilde, and they had ↑ up arrow instead of ^ caret and ← left arrow instead of _ underscore. Trigraphs and digraphs Curly braces are a prominent part of C syntax, used for blocks. For example: int main(int argc, char *argv[]) { printf("hello, world!\n"); } To support character sets without these characters, C89 invented trigraphs, so { could be written as ??< and } as ??>: int main(int argc, char *argv[]) ??< printf("hello, world!\n"); ??> The trigraph ??/ for \ backslash can be used at the end of a line to produce a line continuation, which was lexical undefined behavior when within a universal character name. I encountered this case while writing a static analysis, but it was later fixed in C++26 . Then, C95 introduced nicer-looking digraphs, so { can be written as <% and } as %>: int main(int argc, char *argv[]) <% printf("hello, world!\n"); %> But, trigraphs were only introduced after the Teletype Model 33 w...
First seen: 2026-05-24 16:56
Last seen: 2026-05-24 21:00