Dialect of programming language C

In 1978 Kernighan and Ritchie published a book called “The C Programming Language”. It became an unofficial standard for the language for the next decade, and the version the first edition describes is known as “K&R C” (the second edition focuses on ANSI C).

K&R introduced the following language features:

  • standard I/O library
  • records (struct)
  • long int and unsigned int data types
  • compound operators like =+ were replaced with += (old notation was ambiguous in expressions like i=-10 which could be interpreted both as i =- 10 and i = -10)

K&R C is considered to be the core part of the language which should be supported by any compiler. Even after ANSI C was accepted, programmers who wanted their code to be portable used K&R C, since not all compilers supported later language features.