Talk:Monad (functional programming): Difference between revisions

Content deleted Content added
A couple replies
Zyansheep (talk | contribs)
add comment
Line 10:
:For the code snippets specifically, there is a pretty clear consensus to minimize Haskell on the page (outside of one or two examples, like IO, for flavor). The catch is there's no real guidance on Wikipedia for ''functional'' pseudocode, so when I was doing a lot of editing, I wound up settling on a pseudocode that still looks a lot like Haskell. The thinking there was that it is concise, abstract, de-emphasizes execution order, and often resembles functional math notation, especially if you leave things like lambda calculus implied. But there was also a bit of incrementalism in that decision. I left a long, rambling debriefing for my choices [[Talk:Monad (functional programming)/Archive 2#Style and pseudocode|in the talk archives]].
:If you do have something else in mind though, I'd go for it. I think pseudocode as close as possible to basic math notation (mapping arrows, "f(x)" style functions, etc.) fits this topic well, especially for the (granted, probably very rare) non-programmers that stumble onto the article. So I lean more towards something that looks like Haskell than imperative code in this case, even if it's a popular language, but that's just me. --[[User:Zar2gar1|Zar2gar1]] ([[User talk:Zar2gar1|talk]]) 21:20, 23 June 2021 (UTC)
:I just rewrote the ''An Example: Maybe'' monad section and the introduction to use less haskell as well as being more clear. I used Rust for the code which is my preferred language and I think has similar syntax to other popular languages like Python & C++. I will try to do the rest if I have time. Any critiques? I'm a little new to Wikipedia editing. [[User:Zyansheep|Zyansheep]] ([[User talk:Zyansheep|talk]]) 05:44, 22 November 2021 (UTC)
 
== We should dehaskelize it ==