4 ms·
I don’t really see the usefulness of this. If you write your program this way, how does it interact with the environment (e.g user input, output, network…)? So
by brap 4y ago
I don’t really see the usefulness of this.
If you write your program this way, how does it interact with the environment (e.g user input, output, network…)? Something is missing.
And if it doesn’t interact with the environment, then your program is just one big pure function, in which case you get all of the benefits in OP’s proposal anyway, without having to worry about transforming old state to new state, you just gotta transform input to output.
- robertlagrant 4y ago> If you write your program this way, how does it interact with the environment (e.g user input, output, network…)? The answer is, of course, monads[0]. Probably. [0] https://dl.acm.org/doi/10.1145/158511.158524 https://dl.acm.org/doi/10.1145/158511.158524
- aappleby 4y agoAuthor here. In Backus's paper, the next-state function accepts a (state, input) tuple and returns a (state, output) tuple.