So the story begins with CPL, a programming language that was cooked up initially at Cambridge in the UK, and later expanded to include the University of London. It was originally the Cambridge Programming Language, then the Combined Programming Language. Or, informally, it was called Chris’s Programming Language after lead architect Christopher Strachey.
The language suffered from a poorly governed set of requirements and a lack of a hierarchy regarding implementation. Thus, for example, a lot of time was wasted trying to figure out how to avoid using an explicit multiplication symbol so that would be read as , instead of as an erroneous reference to a nonexistent variable.
Martin Richards at Cambridge, with pressure from end users to finish the language mounting, reduced CPL to a minimum feature set and wrote a bootstrap compiler for it. A bootstrap compiler is one that has a small set of code that needs to be adjusted for a new computer architecture. This subset forms a very primitive compiler, but it is sufficient to compile the code of the complete compiler, which uses only a subset of the compiled language. Thus the compiler, in a sense, bootstraps itself into existence.
Richards called his version BCPL (Bootstrap CPL)
When Richards took a sabbatical to MIT he brought BCPL with him.
MIT at this time was working with Bell Labs on an operating system called Multics. This meant there was a dedicated data link between the two organizations.
Ken Thompson is an inveterate explorer of things—he found the legendary PDP-7 on which Unix was first written while exploring spaces reserved for the Acoustical and Behavioral Research Center—and he found BCPL while poking around an MIT mainframe.
He downloaded it, started using it, and liked what he saw.
After he wrote Unix on that discarded PDP-7 he took BCPL and compressed it down to something that would load into half of the PDP-7’s 8,000 word memory, leaving the other half for programs.
He dubbed the language B, not, as Dennis Ritchie recalled, in reference to Bon, but because he viewed it as being about 25% of BCPL.
He also changed the syntax dramatically. Thompson later called B “BCPL semantics with Algol syntax.”
Thompson also added some innovations to squeeze B programs into less space.
This was because B was originally an interpreted language, not a compiled one. The source code had to fit into 4k, so Thompson cooked up shortcuts like to increment and to decrement.
Anyway, Dennis Ritchie sort of adopted B after that and extended it, turning it into NB (New B).
Meanwhile, Thompson was working on porting Unix to the PDP-11 and rewriting it in NB. Every time he ran into a snag he'd ask Ritchie to add features to NB. Finally he requested that NB include structures. Now structures were not a part of BCPL, and were such a dramatic change to the programming language that Ritchie and Thompson agreed a new name was needed, and thus C was born.
