Early vs Late Binding and Major Programming Paradigms
Classified in Computers
Written on in
English with a size of 2.69 KB
Early Binding
Early binding — the binding that can be resolved at compile time by the compiler is known as static or early binding. The method definition and the method call are linked during compile time. This happens when all information needed to call a method is available at compile time. Early binding is more efficient than late binding.
Late Binding
Late binding — it is a runtime process. The method definition and the method call are linked during runtime. Execution speed is lower in late binding. Overriding methods are bound using late binding.
Programming Paradigms
Below are common programming paradigms and their characteristics.
Object-Oriented Programming (OOP)
Object-oriented programming is a programming paradigm based on the concept of objects, which can contain data in the form of fields and code in the form of procedures (methods). It is the most popular programming model among developers. It simplifies software development and maintenance by providing major concepts such as abstraction, inheritance, polymorphism, and encapsulation.
Merits
- Provides modular programming.
- Makes finding bugs easier.
- Provides abstract data types in which some implementation details can be hidden and protected.
Demerits
- In OOP everything is arranged in the form of classes and modules; for lower-level applications this may not be a desirable feature.
Imperative and Procedural Paradigm
Imperative and procedural programming is one of the oldest programming paradigms. It is based on the idea of variables and assignments and focuses mainly on how to achieve a goal by programming step-by-step operations, changing the state of the program at each step. A program consists of a sequence of statements. After execution of its statements, the values are stored in memory.
Merits
- Simple to implement.
- These languages often have low memory utilization.
Demerits
- Large, complex programs cannot be easily implemented using this category of language.
- Less efficient and less productive for some tasks.
- Parallel programming is not always possible or straightforward.
Attributes of a Good Language
Key attributes of a good programming language include:
- Clarity, simplicity, and unity
- Orthogonality
- Naturalness for the application
- Abstraction
- Program verification
- Program environment
- Portability
- Cost of use