Programming Paradigms Overview

IlluminatingNovaculite3231 avatar
IlluminatingNovaculite3231
·
·
Download

Start Quiz

Study Flashcards

10 Questions

A programming ______ is a set of related concepts and different approaches to programming.

paradigm

Imperative languages have explicit commands, specifying how to solve a ______.

problem

Declarative languages specify what needs to be done, without telling how to do ______.

it

Structural Programming emphasizes clear, organized code, with abstracting, ______, and return values, and clear control flow.

parameters

Procedural Programming uses ______ to carry out specific tasks on data, often using structured programming.

subroutines

Object-Oriented Programming uses ______ and classes to encapsulate behavior and data, with benefits and drawbacks.

objects

Functional Programming expresses problems in a ______ way, using subroutines, function calls, and recursion, to specify the desired endpoint.

mathematical

Many programming languages lean towards a particular ______, but may not always be tightly defined.

paradigm

There are two high-level approaches: ______ and declarative languages.

imperative

Experience in multiple ______ can provide context and help in choosing the best approach for a particular problem.

paradigms

Study Notes

Programming Paradigm Overview

  • A programming paradigm is a set of related concepts and different approaches to programming.
  • Each paradigm has its own pros and cons, but ultimately, they should be able to solve the same problems, just in different ways.
  • Experience in multiple paradigms is beneficial, and many programming languages are multi-paradigm, supporting different approaches.

Imperative and Declarative Languages

  • Imperative languages have explicit commands, specifying how to solve a problem.
  • Declarative languages specify what needs to be done, without telling how to do it.
  • Declarative languages, like SQL, express the desired endpoint, and let the compiler or engine figure out how to achieve it.

Imperative Paradigms

  • Structural Programming: emphasizes clear, organized code, with abstracting, parameters, and return values, and clear control flow.
  • Procedural Programming: uses subroutines to carry out specific tasks on data, often using structured programming.
  • Object-Oriented Programming: uses objects and classes to encapsulate behavior and data, with benefits and drawbacks.

Declarative Paradigms

  • Functional Programming: expresses problems in a mathematical way, using subroutines, function calls, and recursion, to specify the desired endpoint.
  • Functional programming is often used in data science and is a more niche and less commonly used paradigm.

Other Key Points

  • Many programming languages lean towards a particular paradigm, but may not always be tightly defined.
  • Programming as a field developed rapidly, and definitions have evolved over time.
  • There are two high-level approaches: imperative and declarative languages.
  • Experience in multiple paradigms can provide context and help in choosing the best approach for a particular problem.

Programming Paradigms Overview

  • A programming paradigm is a set of concepts and approaches to solve problems in different ways, with pros and cons.
  • Each paradigm can solve the same problems, but with different approaches.
  • Experience in multiple paradigms is beneficial, and many languages are multi-paradigm.

Imperative and Declarative Languages

  • Imperative languages use explicit commands to specify how to solve a problem.
  • Declarative languages specify what needs to be done, without explaining how.
  • Declarative languages, like SQL, focus on the desired endpoint and let the compiler figure out how to achieve it.

Imperative Paradigms

Structural Programming

  • Emphasizes clear, organized code with abstraction, parameters, and return values.
  • prioritizes clear control flow.

Procedural Programming

  • Uses subroutines to perform specific tasks on data.
  • Often uses structured programming techniques.

Object-Oriented Programming

  • Uses objects and classes to encapsulate behavior and data.
  • Has benefits and drawbacks.

Declarative Paradigms

Functional Programming

  • Expresses problems in a mathematical way.
  • Uses subroutines, function calls, and recursion to specify the desired endpoint.
  • Often used in data science, and is a niche paradigm.

Other Key Points

  • Many languages lean towards a particular paradigm, but may not be strictly defined.
  • Programming has evolved rapidly, and definitions have changed over time.
  • There are two high-level approaches: imperative and declarative languages.
  • Experience in multiple paradigms provides context and helps choose the best approach for a problem.

Explore different programming paradigms, including imperative and declarative languages, and understand their approaches and benefits.

Make Your Own Quizzes and Flashcards

Convert your notes into interactive study material.

Get started for free

More Quizzes Like This

Use Quizgecko on...
Browser
Browser