[WEBINAR] Application Acceleration: Faster Performance for End Users

Declarative Programming

Definition - What does Declarative Programming mean?

Declarative programming is a programming paradigm in which the programmer defines what needs to be accomplished by the program without defining how it needs to be implemented. In other words, the approach focuses on what needs to be achieved instead of instructing how to achieve it. It is different from an imperative program which has the command set to resolve a certain set of problems by describing the steps required to find the solution. Declarative programming describes a particular class of problems with language implementation taking care of finding the solution. The declarative programming approach helps in simplifying the programming behind some parallel processing applications.

Techopedia explains Declarative Programming

Order of expression or statements or the replication of a statement would not have any impact in declarative programming. Declarative programming can be further categorized into constraint programming, logic programming and constraint logic programming. Prolog, SQL and embedded SQL are some of the well-known examples of declarative programming languages. Tools are provided to programmers in declarative programming to allow abstraction of the implementation and to help in the concentration of the issue.

There are many advantages associated with declarative programming. First of all, it minimizes mutability. Immutable data structures help in eliminating hard-to-detect bugs and are easier to handle. Programmers would find it easier to work with such programming approaches rather than ones with unclear procedures, implicit dependencies or with lots of mutable states. Another benefit with declarative programming is it reduces state side effects by favoring the use of complex constructs like higher order functions and pipelines and by discouraging variables. The programming approach also helps in making the code more understandable and more scalable.

Techopedia Deals

Connect with us

Techopedia on Linkedin
Techopedia on Linkedin
"Techopedia" on Twitter

Sign up for Techopedia's Free Newsletter!

Email Newsletter

Join thousands of others with our weekly newsletter

Free Whitepaper: The Path to Hybrid Cloud
Free Whitepaper: The Path to Hybrid Cloud:
The Path to Hybrid Cloud: Intelligent Bursting To Amazon Web Services & Microsoft Azure
Free E-Book: Public Cloud Guide
Free E-Book: Public Cloud Guide:
This white paper is for leaders of Operations, Engineering, or Infrastructure teams who are creating or executing an IT roadmap.
Free Tool: Virtual Health Monitor
Free Tool: Virtual Health Monitor:
Virtual Health Monitor is a free virtualization monitoring and reporting tool for VMware, Hyper-V, RHEV, and XenServer environments.
Free 30 Day Trial – Turbonomic
Free 30 Day Trial – Turbonomic:
Turbonomic delivers an autonomic platform where virtual and cloud environments self-manage in real-time to assure application performance.