19 ms·
This is one of the biggest reasons I like Cardano. It's written in Haskell and its contract language is functional and heavily inspired - meaning that code gets
by mattwilsonn888 5y ago
This is one of the biggest reasons I like Cardano. It's written in Haskell and its contract language is functional and heavily inspired - meaning that code gets many of the functional benefits: it is more concise, more readable, less prone to side effects, and more often than non-functional code won't run at all if mistakes are made.
The trade offs in functional languages seem to well suited for the world of smart contracts, that I almost think of smart contracts as the retro-active problem that functional programming solves. Granted, I appreciate functional programming and good code enough where I wish all code met the standards required for FP, but the real world is much messier; when large amounts of money are so directly on the line though I think its obvious the compromise is worth it.
Smart contracts are like launching a rocket - you don't optimize for development time. FP forces a bit more safety.