Angular Nested Routing
Programming paradigms are common ways to solve a problem using a set of techniques. They can be thought of as strategies of writing code to solve a challenge using a certain programming style or language.
There are a vast variety of software languages and they can be classified into multiple programming paradigms. To classify a programming language as one paradigm, we can look at their execution model, their code organization or their syntax and grammar.
In this article we are going to review the most common programming paradigms and list some examples of software languages on each paradigm.
The imperative programming paradigm is based on assignment statements that change the internal state of a program. The execution of the program is done via step by step modifications to the program’s state.
Imperative programming focuses on how the program is executed. It executes the assignments line by line as they are written. It is an explicit paradigm. This can be contrasted by the declarative programming paradigm which focuses on what the program has to accomplish.
The imperative programming is a generic paradigm which includes the following paradigms:
A declarative programming paradigm is an implicit style of programming. It focused on what the program has to execute rather than how to solve the problem. If in the imperative paradigm we describe the program’s execution line by line, in declarative programming we focus on telling what we want the program to execute.
The key to declarative programming is that the language describes what are the final results we expect rather than the step-by-step commands to execute. A declarative program does not get involved in the logic behind scenes. That is why it is known as not to have side-effects.
There are multiple paradigms that can be grouped inside the Declarative Programming Paradigm:
The Event Driven Paradigm is a programming style which creates programs that react to events in order to execute logic. The most common way of event driven programming is reacting to user inputs or clicks. Event-driven programs gain popularity due to the increase of mobile devices and web-applications with powerful front-end frameworks.
At the core of an event-driven program there is a scheduler process that keeps track of the received events and forwards them into the respective event-handlers. The events are usually identified by IDs and they contain internal data of the event which can be retrieved by the logic reacting to the event. It is common for event-handlers to trigger other events, thus creating a chain reaction of events.
Exceptions are usually raised by the event scheduler if it can’t find an event-handler or from the event-handler itself if the event data does not meet the expectations.
It is common for the event scheduler process to receive multiple events simultaneously, this is where the event queue enters the play. An event queue allows multi-thread execution in a program and is responsible for queuing the events. Event queues ensure each event-handler receives event notifications. It also allows for managing event priority, meaning that certain events might take priority over others based on their type.
This article has covered the most common programming paradigms. There are more paradigms related to programming. Here is a list to name a few:
A basic but helpul introduction to Algorithm Complexity Analysis. An overview of tools for analysing algorithms and representing their complexity.
Flutter is a multi-platform framework built by Google and used to develop native applications for web, mobile and desktop from a single code base. Here we review key ideas, concepts and introduction Tutorials to Flutter.