Ramda JS Tutorial – Part 22 (cond / switch case)

preview_player
Показать описание
How to express a switch case scenario in functional programming.

Let's understand all the functions of the JavaScript library Ramda JS and learn a lot about functional programming as we go along.

⭐️ Support the channel on Patreon:

👾 In this video:
R.cond (+ ifelse)

🖥 Full playlist:
Рекомендации по теме
Комментарии
Автор

This execute 30 times faster. What am I doing wrong?
hash = ({0 : 'water freezes at 0°C', 100 : 'water boils at 100°C'})
fnb = (temp) => hash[temp] || 'nothing special happens at ' + temp + '°C'

christernilsson
Автор

It's been a while, nice to see another great video.

Sleerk
Автор

I think Haskell for example just throws exception if you miss on pattern match and don't have default case. The types have to match anyway before hand but the values cannot be known before the computation.

metalwarrior
Автор

Good to see you back! Also is that a new mic?

Anyway, have you thought about a Patreon?

TheFlamePhoenix
Автор

And one day Christopher came back! Great video

facundorodriguez
Автор

keep the vid coming, this is great :)

zeocamo