PROGRAMMING PARADIGM
A 'programming paradigm' is a fundamental style of programming regarding how solutions to problems are to be formulated in a programming language. (Compare with a methodology, which is a style of solving specific software engineering problems).
A programming paradigm provides (and determines) the view that the programmer has of the execution of the program. For instance, in object-oriented programming, programmers can think of a program as a collection of interacting objects, while in functional programming a program can be thought of as a sequence of stateless function evaluations. When programming computers or systems with many processors, process oriented programming allows programmers to think about applications as sets of concurrent processes acting upon logically shared data structures.
Just as different groups in software engineering advocate different ''methodologies'', different programming languages advocate different ''programming paradigms''. Some languages are designed to support one particular paradigm (Smalltalk and Java support object-oriented programming while Haskell supports functional programming), while other programming languages support multiple paradigms (such as C++, Common Lisp, Scheme, Python, Ruby and Oz).
Many programming paradigms are as well-known for what techniques they ''forbid'' as for what they enable. For instance, pure functional programming disallows the use of side-effects; structured programming disallows the use of goto. Partly for this reason, new paradigms are often regarded as doctrinaire or overly rigid by those accustomed to earlier styles. However, this avoidance of certain techniques can make it easier to prove theorems about a program's correctness—or simply to understand its behavior—without limiting the generality of the programming language.
The relationship between programming paradigms and programming languages can be complex since a programming language can support multiple paradigms. For example, C++ is designed to support elements of procedural programming, object-oriented programming and generic programming. However, designers and programmers decide how to build a program using those paradigm elements. One can write a purely procedural program in C++, one can write a purely object-oriented program in C++, or one can write a program that contains elements of both paradigms.
★ Annotative programming (as in Flare language)
★ Aspect-oriented programming (as in AspectJ)
★ Attribute-Oriented Programming (as in Java 5 Annotations, pre-processed by the XDoclet class; C# Attributes)
★ Class-based programming, compared to Prototype-based programming (within the context of object-oriented programming)
★ Concept-oriented programming is based on using concepts as the main programming construct.
★ Constraint programming, compared to logic programming
★ Dataflow programming (as in spreadsheets)
★ Flow-driven programming, compared to event-driven programming
★ Function-level programming
★ Functional programming
★ Imperative programming, compared to declarative programming
★ Logic programming (as in Prolog)
★ Message passing programming, compared to imperative programming
★ Nondeterministic programming
★ Object-oriented programming (as in Smalltalk)
★ Pipeline programming (as in the UNIX command line)
★ Policy-based programming
★ Procedural programming, compared to functional programming
★ Process-oriented programming a parallel programming model.
★ Reactive programming
★ Recursive programming, compared to iterative programming
★ Reflective programming
★ Scalar programming, compared to Array programming
★ Component-oriented programming (as in OLE)
★ Structured programming, compared to unstructured programming
★ Subject-oriented programming
★ Tree programming
★ Value-level programming, compared to function-level programming
★ Language-oriented programming
★ ARS based programming
★ Grammar-oriented programming
A programming paradigm provides (and determines) the view that the programmer has of the execution of the program. For instance, in object-oriented programming, programmers can think of a program as a collection of interacting objects, while in functional programming a program can be thought of as a sequence of stateless function evaluations. When programming computers or systems with many processors, process oriented programming allows programmers to think about applications as sets of concurrent processes acting upon logically shared data structures.
Just as different groups in software engineering advocate different ''methodologies'', different programming languages advocate different ''programming paradigms''. Some languages are designed to support one particular paradigm (Smalltalk and Java support object-oriented programming while Haskell supports functional programming), while other programming languages support multiple paradigms (such as C++, Common Lisp, Scheme, Python, Ruby and Oz).
Many programming paradigms are as well-known for what techniques they ''forbid'' as for what they enable. For instance, pure functional programming disallows the use of side-effects; structured programming disallows the use of goto. Partly for this reason, new paradigms are often regarded as doctrinaire or overly rigid by those accustomed to earlier styles. However, this avoidance of certain techniques can make it easier to prove theorems about a program's correctness—or simply to understand its behavior—without limiting the generality of the programming language.
The relationship between programming paradigms and programming languages can be complex since a programming language can support multiple paradigms. For example, C++ is designed to support elements of procedural programming, object-oriented programming and generic programming. However, designers and programmers decide how to build a program using those paradigm elements. One can write a purely procedural program in C++, one can write a purely object-oriented program in C++, or one can write a program that contains elements of both paradigms.
| Contents |
| Examples |
| See also |
Examples
★ Annotative programming (as in Flare language)
★ Aspect-oriented programming (as in AspectJ)
★ Attribute-Oriented Programming (as in Java 5 Annotations, pre-processed by the XDoclet class; C# Attributes)
★ Class-based programming, compared to Prototype-based programming (within the context of object-oriented programming)
★ Concept-oriented programming is based on using concepts as the main programming construct.
★ Constraint programming, compared to logic programming
★ Dataflow programming (as in spreadsheets)
★ Flow-driven programming, compared to event-driven programming
★ Function-level programming
★ Functional programming
★ Imperative programming, compared to declarative programming
★ Logic programming (as in Prolog)
★ Message passing programming, compared to imperative programming
★ Nondeterministic programming
★ Object-oriented programming (as in Smalltalk)
★ Pipeline programming (as in the UNIX command line)
★ Policy-based programming
★ Procedural programming, compared to functional programming
★ Process-oriented programming a parallel programming model.
★ Reactive programming
★ Recursive programming, compared to iterative programming
★ Reflective programming
★ Scalar programming, compared to Array programming
★ Component-oriented programming (as in OLE)
★ Structured programming, compared to unstructured programming
★ Subject-oriented programming
★ Tree programming
★ Value-level programming, compared to function-level programming
See also
★ Language-oriented programming
★ ARS based programming
★ Grammar-oriented programming
This article provided by Wikipedia. To edit the contents of this article, click here for original source.
psst.. try this: add to faves

العربية
中国
Français
Deutsch
Ελληνική
हिन्दी
Italiano
日本語
Português
Русский
Español