diff options
| author | Miguel <m.i@gmx.at> | 2019-03-17 12:13:01 +0100 |
|---|---|---|
| committer | Miguel <m.i@gmx.at> | 2019-03-17 12:13:01 +0100 |
| commit | fec672748d0e4ccf76b6631e81c0ae941f54ea7f (patch) | |
| tree | dd3fdd91bfedc11cb8bcbf2ddf7f50bf9ca925f8 /snip/snip.hs | |
| parent | 9d1659957b81ba3655cc16e4d47426ca154b287b (diff) | |
added snippets
Diffstat (limited to 'snip/snip.hs')
| -rw-r--r-- | snip/snip.hs | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/snip/snip.hs b/snip/snip.hs new file mode 100644 index 0000000..532329f --- /dev/null +++ b/snip/snip.hs @@ -0,0 +1,2 @@ +-- monad transformers in action +Main Control.Monad.Writer Control.Monad.State> runState (runWriterT (get >>= \a -> tell ["foo"] >> put (a*a) >> tell ["bar"] >> tell [show a])) 5 |
