These are my notes on the lectures on the topic of Monads imparted by Irfan Ali between May 27 and June 7, 2022.
- Motivating example
- The Monad class
- List monad
- State monad
{-# LANGUAGE OverloadedStrings #-} | |
module Example where | |
import Language.Marlowe.Extended | |
np = 3 :: Integer -- Number of payments (positive integer) | |
am = 50 :: Integer -- Amount (in Ada) of each deposit by Client (positive integer) | |
main :: IO () | |
main = printJSON $ contract np am (TimeParam "Bank Deadline") (TimeParam "Client Deadline") |
These are my notes on the lectures on the topic of Monads imparted by Irfan Ali between May 27 and June 7, 2022.
{"valueParameterInfo":[],"timeParameterDescriptions":[],"roleDescriptions":[],"contractType":"Other","contractShortDescription":"Unknown","contractName":"Unknown","contractLongDescription":"We couldn't find information about this contract","choiceInfo":[]} |
{"valueParameterInfo":[],"timeParameterDescriptions":[],"roleDescriptions":[],"contractType":"Other","contractShortDescription":"Unknown","contractName":"Unknown","contractLongDescription":"We couldn't find information about this contract","choiceInfo":[]} |
{"valueParameterInfo":[],"timeParameterDescriptions":[],"roleDescriptions":[],"contractType":"Other","contractShortDescription":"Unknown","contractName":"Unknown","contractLongDescription":"We couldn't find information about this contract","choiceInfo":[]} |