Second-generation programming language
   HOME

TheInfoList



OR:

The label of second-generation programming language (2GL) is a generational way to categorize
assembly language In computer programming, assembly language (or assembler language, or symbolic machine code), often referred to simply as Assembly and commonly abbreviated as ASM or asm, is any low-level programming language with a very strong correspondence b ...
s."Computer Hope, Generation languages"
/ref> The term was coined to provide a distinction from higher level machine independent
third-generation programming language A third-generation programming language (3GL) is a high-level computer programming language that tends to be more machine-independent and programmer-friendly than the machine code of the first-generation and assembly languages of the second-gene ...
s (3GLs) (such as
COBOL COBOL (; an acronym for "common business-oriented language") is a compiled English-like computer programming language designed for business use. It is an imperative, procedural and, since 2002, object-oriented language. COBOL is primarily u ...
, C, or
JavaScript JavaScript (), often abbreviated as JS, is a programming language that is one of the core technologies of the World Wide Web, alongside HTML and CSS. As of 2022, 98% of websites use JavaScript on the client side for webpage behavior, of ...
) and earlier
first-generation programming language A first-generation programming language (1GL) is a machine-level programming language. A first generation (programming) language (1GL) is a grouping of programming languages that are machine level languages used to program first-generation com ...
s (
machine code In computer programming, machine code is any low-level programming language, consisting of machine language instructions, which are used to control a computer's central processing unit (CPU). Each instruction causes the CPU to perform a ve ...
)


Second-generation programming language

Second-generation programming languages have the following properties: *Lines within a program correspond directly to processor commands, essentially acting as a mnemonic device overlaying a first generation programming language. *The code can be read and written by a programmer. To run on a computer it must be converted into a machine readable form, a process called assembly. *The language is specific to a particular processor family and environment. Second-generation languages are sometimes used for parts of
kernel Kernel may refer to: Computing * Kernel (operating system), the central component of most operating systems * Kernel (image processing), a matrix used for image convolution * Compute kernel, in GPGPU programming * Kernel method, in machine learn ...
s or device drivers, and are sometimes used in video games, graphics programs, and other intensive programs. In modern programs, second generation assembly languages are rarely used. Programming in second generation languages may yield speed benefits, but several disadvantages have led to its decline: * Programming is expressed in terms of individual processor instructions, rather than higher level logic. * Low-level memory and hardware details must be manually managed which is often bug-prone. * Programs are
machine-dependent Machine-dependent software is software that runs only on a specific computer. Applications that run on multiple computer architectures are called machine-independent, or cross-platform. Many organisations opt for such software because they believe t ...
, so different versions must be written for every target machine architecture. The vast majority of programs are written in a
third-generation programming language A third-generation programming language (3GL) is a high-level computer programming language that tends to be more machine-independent and programmer-friendly than the machine code of the first-generation and assembly languages of the second-gene ...
or a
fourth-generation programming language A fourth-generation programming language (4GL) is any computer programming language that belongs to a class of languages envisioned as an advancement upon third-generation programming languages (3GL). Each of the programming language generations a ...
. Assembly's main advantage, speed, has degraded by the fact that well written C code can often be as fast or even faster than hand written assembly Second generation languages are perhaps most significant in their place in computing history. For a long time, Second generation assembly languages were the only good option for development for many machines, such as the NES or the
Commodore 64 The Commodore 64, also known as the C64, is an 8-bit home computer introduced in January 1982 by Commodore International (first shown at the Consumer Electronics Show, January 7–10, 1982, in Las Vegas). It has been listed in the Guinness W ...
. Second generation languages represented a massive step away from the tradition of programmers conforming to the needs of a machine, and the first step towards the machine accommodating for the programmer, a phenomenon that would be repeated in all subsequent programming language generations.


See also

*
First-generation programming language A first-generation programming language (1GL) is a machine-level programming language. A first generation (programming) language (1GL) is a grouping of programming languages that are machine level languages used to program first-generation com ...
*
Third-generation programming language A third-generation programming language (3GL) is a high-level computer programming language that tends to be more machine-independent and programmer-friendly than the machine code of the first-generation and assembly languages of the second-gene ...
*
Fourth-generation programming language A fourth-generation programming language (4GL) is any computer programming language that belongs to a class of languages envisioned as an advancement upon third-generation programming languages (3GL). Each of the programming language generations a ...
*
Fifth-generation programming language A fifth-generation programming language (5GL) is any programming language based on problem-solving using constraints given to the program, rather than using an algorithm written by a programmer. Most constraint-based and logic programming langua ...


References

{{Programming language generations Programming language classification