The difference between a compiled and interpreted programming language.

Computers don’t understand high-level languages, so, it’s required to convert a high-level language into a low-level language. So, there are two ways to do this task. The first one is the compiler, which converts the whole program into object code. So, the memory requirement is higher in the case of the compiler, and after that, we just need to execute the object code to run the program. So, the compiler has a fast execution process.

On the other hand, the interpreter scans the first line of code. If there is no error, the interpreter converts it into machine mode and repeats the same process line by line. That’s why the process of execution of a program is slow in an interpreter and the memory requirement for an interpreter is less as compared to the compiler. 

What a programming paradigm is ?

programming paradigm means the way you write a program. So, different paradigms of programming mean different styles of programming. Initially, there was only one programming paradigm- Assembly language which included the commands like MOVE, READ, ADD, etc. For example, if we want to ADD content of 2 registers we use (ADD R1, R2).

We have four types of programming paradigms -:

  1. Imperative /procedural program

Consist of a sequence of statements
After execution of statements, values are stored in memory.

Features-:

Contain variables and iterations

Simple to implement

Low memory utilization

Demerits-:

Complex problems cant be implemented

Parallel programming is not possible

2. Object-oriented programming :

Data & functions are bound in one entity called class.

everything is modeled as an object

Modular programming approach

Features-:

Data abstraction

Encapsulation

Inheritance

Polymorphism

Easily debugged & modified

3. Functional programming :

Computations are expressed in functions

Functions are applied to values (10+20)= 30

Development of complex function from single function

Features-:

Comprehensible due to functions

Functions are reusable

A large number of functions are maintained

Demerits-:

Consume a large amount of time and memory

Not good for commercial software development

4. Logic programming:

Computations are expressed in mathematical logic

Declarative programming approach

Features-:

Reliable

It’s quickly developed as it makes use of true & false statements

Demerits-:

Slow execution

True & false can not solve most of the problems

“5 high-level programming languages”

  1. JavaScript

Javascript was invented by Brenden Eich in 1995 when he was working with the Netscape community. Netscape was the famous browser at that time.
After some time Netscape navigators felt that they should make a programming language that can introduce interactivity in websites. Brenden Eich made this programming language in just 10 days. Initially, the name of javascript was Mocha then they changed its name to LiveScript but it was not getting popular.  At that time Java was very popular among programmers. So, their marketing team decided to change the name from  LiveScript to JavaScript.
In 1996 internet explorer was the biggest competitor of Netscape. So, internet explorer felt that Netscape is getting more popular because of javascript. so, Microsoft decided to create a new programming language called Jscript.

So, it’s very difficult for the programmer to select between these two languages. If they use javascript their website looks good in Netscape but not in internet explorer and vice versa. After that ECMA (European Computer Manufacturers Association) standardized some rules that every browser must follow. So, in 1997 ES1 was introduced and every browser must implement it.
Javascript is an interpreted language and has multiple paradigms which include:- object Oriented programming, Functional programming, and procedural programming and you can freely mix these Javascript paradigms. Javascript is a widely-used programming language it’s used in Microsoft office, Netflix, Facebook, and many more products.

2. Python

Python was invented by Guido van Rossum in 1989 when he was working at the National research institute in the Netherlands and it was officially released on 20 February 1991. Python is very simple and has straightforward syntax. The name Python was picked from the Tv show Monty Python’s Flying Circus. In 1994, python 1.0 was released with some new features like lambda, map, filter, and reduce. Python is very famous for Data analysis and processing and artificial intelligence.
Python is an interpreted language which means before execution the source code of a python program is converted into bytecode. It has multiple paradigms which include -: Object-Oriented programming language, imperative and functional. Python is widely used in world-class companies like Google, Facebook, quora, and the very famous social media app Instagram also uses python programming language.

3. Java

Java was developed by James Gosling at Sun Microsystems in 1995. Java language derives much of its syntax from C and C++, but it has fewer low-level facilities than either of them. Java was originally designed for interactive television, but it was too advanced for the digital cable television industry at the time. The language was initially called Oak, which was a tree. After that, the project name was changed to Green and finally renamed Java. It promised, “write once, run anywhere”. Java is fairly secure and features configurable security and major web browsers soon incorporated the ability to run Java applets within web pages. JVM and ByteCode make its architecture natural that’s why it supports every device. JVM and ByteCode are actually programs and codes where JVM is aĀ java virtual machine and ByteCode is a code that understands by JVM. Java is both interpreted and compiled language because java first compiled into a binary code and after that byte code runs on Java virtual machine. The paradigm of java is an imperative, declarative, and Object-Oriented programming language. Java has many real-world applications like it is used create GUI applications for desktop, mobile applications, and the most famous Android operating system is also made with java.Ā 

4. Swift

Swift is developed by Apple Inc and it has first appearedĀ on 2nd June 2014. It was developed to replace the Objective-C programming language which is earlier used by Apple. The development of swift was started in 2010 by Chris Lattner and other programmers. To date,Ā it’s a very powerful language for the Apple ecosystem which includes Mac operating system, WatchOs, and ios. Swift has a very clear and expressive syntax which helps programmers to write more accurate programs than in other languages. Xcode IDE is required for the development of apple applications that are integrated with Cocoa touch frameworks. Swift is a multi-paradigm language that includes protocol-oriented, object-oriented, functional, imperative, block-structured, declarative. Swift is a compiled language which means its source code is compiled to the assembly code is compiled to the machine code using the LLVM tool that’s why this is a very fast programming language. Swift programming language is used in making Facebook, Uber, Slack, WhatsApp, and many more products.Ā 

5. PHP

Php is developed by Rasmus Lerdorf at Zend technologies and the first version has appearedĀ on 8th June 1995. PHP is one of the most popular open-source programming languages which is a server-side scripting language, which means that the application was written to run on a web server and does not dependĀ on the browser. It is developed especially for the development of web applications. Initially, Rasmus Lerdorf wrote PHP to maintain his personal home page and after that, he extended it to communicate with the database file system. Initially, the name of PHP was PHP/FI (Personal Home Page/Form interpreter) but after some time it was changed to PHP which stands for Hypertext Preprocessor It is an interpreted language and has a multi-paradigm which includes imperative, functional, object-oriented, procedural, and reflective. PHP was used to create many real-world products like Facebook, Yahoo, Wikipedia, WordPress, and many more. WordPress is the most popular content management system on the internet.Ā