reading-notes


Project maintained by mr-atta Hosted on GitHub Pages — Theme by mattgraham

Functional

📍Functional Programming Concepts

## What is functional programming ❓

FP

Functional programming is a programming paradigm — a style of building the structure and elements of computer programs — that treats computation as the evaluation of mathematical functions and avoids changing-state and mutable data .

## What is a pure function and how do we know if something is a pure function ❓

A pure function is a function which: 1.Given the same input, will always return the same output. 2.Produces no side effects. ## What are the benefits of a pure function ❓

  • Big advantages to build side-effect-free functions. <hr> easier to maintain systems. <hr> easier to read. <hr> we can quickly understand a function.

## What is immutability ❓

Unchanging over time or unable to be changed. When data is immutable, its state cannot change after it’s created. If you want to change an immutable object, you can’t. Instead, you create a new object with the new value.

## What is Referential transparency ❓

‘pure functions + immutable data = referential transparency’

Node JS Tutorial for Beginners

Modules and require()

## What is a module❓

A module is a file. One script is one module.

Modules can load each other and use special directives export and import to interchange functionality, call functions of one module from another one.

## What does the word ‘require’ do❓

Global , take a path.

The require() method is used to load and cache JavaScript modules. So, if you want to load a local, relative JavaScript module into a Node. js application, you can simply use it.

## How do we bring another module into the file the we are working in❓

require(‘./.path')

## What do we have to do to make a module available❓

module.exports=

📍 To Ceack Later

♥️from <hr> ♥️from



<hr>

♥️from ♥️from