官术网_书友最值得收藏!

  • PHP Reactive Programming
  • Martin Sikora
  • 139字
  • 2021-07-09 19:06:15

Declarative programming

Declarative programming is a paradigm focused on describing a program's logic instead of particular executional steps. In other words, in declarative programming, we define what we want instead of how we want it. In contrast to imperative programming, programs in declarative programming are defined with expressions instead of statements.

Very common examples could be SQL and HTML languages. Consider the following database query:

SELECT * FROM user WHERE id = 42 

In SQL, we define what data from what table we want to query, but the implementation details are completely hidden for us. We don't even want to worry about how the database engine stores or indexes the data.

In HTML, we define the structure of elements; what's behind the browser's rendering process isn't important for us. We just want to see the page on the screen.

主站蜘蛛池模板: 星座| 香港 | 东安县| 建始县| 溧阳市| 依安县| 胶南市| 苏州市| 景宁| 石城县| 馆陶县| 浏阳市| 会宁县| 错那县| 石台县| 佛山市| 芜湖市| 安庆市| 垣曲县| 红原县| 外汇| 凌云县| 朝阳市| 始兴县| 崇左市| 延边| 遵化市| 秦皇岛市| 普陀区| 延寿县| 抚远县| 乾安县| 文成县| 喀什市| 华池县| 江永县| 辽宁省| 文化| 梧州市| 南投县| 聂拉木县|