Imperative programming
lastmod 2015-06-18created 2015-06-181 edits
In computer science, imperative programming is a programming paradigm, opposed to declarative programming, that describes computation in terms of program state and statements that change that state. Just as the imperative mood in natural languages expresses commands for actions to take, an imperative program is a sequence of commands for the computer to perform, written in order.
Nearly all computer hardware is implemented imperatively. Nearly all computer hardware is designed to execute machine code, the computer's native language, which is written in an imperative style. From a low-level perspective, program state is defined by the contents of memory, and statements are defined by machine code instructions.
The first imperative languages were the machine languages of primitive computers. Machine language instructions were very simple, which made hardware easy to implement, but writing complex programs was difficult. FORTRAN, developed by John Backus at IBM in 1954, removed these obstacles of machine language and was the first major language capable of writing complex programs.