3 ms·
> All that said, if you're thinking in terms of multiple inputs and outputs you're missing the point. The output isn't a pair, it's one or the other, and that's
by renox 8y ago
> All that said, if you're thinking in terms of multiple inputs and outputs you're missing the point. The output isn't a pair, it's one or the other, and that's really important
Only in the example showed in the website, if you want to have progress reports/feedback on your happy path and keep it even if you go to the error path then having a multiple result/structure containing both results at the same time make sense.
- lmm 8y agoSure, and there are structures you can use for that (e.g. Writer). But that's kind of the easy part: every serious programming language allows some kind of pair structure, but a lot of languages still don't have a good "A or B but not both" structure.