This is a summary of the "Learn You A Haskell" online book under http://learnyouahaskell.com/chapters.
- Haskell is a functional programming language.
This is a summary of the "Learn You A Haskell" online book under http://learnyouahaskell.com/chapters.
This is not intended to be comprehensive or authoritative, just free online resources I've found valuable while learning more about Erlang.
import Control.Monad | |
------------------------------------------------------------------------------- | |
-- State Monad Implementation | |
------------------------------------------------------------------------------- | |
newtype State s a = State { runState :: s -> (a,s) } | |
instance Monad (State s) where | |
return a = State $ \s -> (a, s) |
Okay, so I'll try and walk through the reader monad as best as I can. And | |
because I think it helps to de-mystify things a bit, I'll also go through | |
all of the "super classes" of monad: functor and applicative (because every | |
monad should also be an applicative and every applicative functor should be | |
a functor). This file is literate Haskell so you should just be able to | |
load it in the REPL or run it. It's also kinda/sorta markdown, so it should | |
render that way as well (but the code is formatted wrong). | |
> module Reader where |
Useful links about freepascal in telegram etc
Please suggest us other links and lib usefull for telegram in FreePascal/Lazarus and FreePascal in telegram!
For the past two weeks or so, I've been working on a little compiler project in C, mostly for educational purposes, i.e. to understand how a compiler really works. I'm not using any libraries, other than the C runtime library.
I have a hand-written lexer and parser, and a simple code generator targetting
Here's a list of mildly interesting things about the C language that I learned mostly by consuming Clang's ASTs. Although surprises are getting sparser, I might continue to update this document over time.
There are many more mildly interesting features of C++, but the language is literally known for being weird, whereas C is usually considered smaller and simpler, so this is (almost) only about C.
struct foo {
struct bar {
int x;