User talk:Hout

From Rosetta Code

Repairing lost visibility of formula elements[edit]

Over the last six months, a well-intentioned but under-tested campaign of cosmetic edits accidentally eliminated the visibility of formulae (to the majority of browsers) in the task descriptions of over 60 different Rosetta tasks.

I have now restored the visibility of formulae to some of these tasks, generated a list of the tasks whose descriptions remain in need of repair,

(see below)

and added a note to the discussion page of each, identifying the date and time of the accidentally destructive edit.

I have, however, had enough of this now, and others are welcome to contribute to all or any of the outstanding repairs.

TECHNICAL NOTE Many of the inadvertently destructive edits accidentally choked the MediaWiki processor by introducing redundant spaces around the content of <math> tags, leading to the generation of defective HTML, and allowing only a minority type of browser to view the formula. Unfortunately, this turns out to have been the only kind of browser that was being used in the testing of the edits. The two types of browsers are: 1. The majority, including Chrome, Safari, IE, which display the <math> content from the 'fallback' graphic file on the server. 2. The minority, including FireFox, which, when requisite fonts are installed, generate the formula image by local processing of MathML expressions.

It is very important to test any edits involving <math> tags on both types of browser. Hout (talk) 22:22, 22 September 2016 (UTC)

Update[edit]

My thanks to user Wswiss for updating the Statistics/Basic page, which alerted me to the fact that I hadn't scanned tasks with a forward slash in their name, and that there are more damaged tasks (formula visibility accidentally removed during an under-tested cosmetic edit) than I had thought.

The current number of unrepaired tasks (with some or all formulae made invisible to most browsers), is 56.

In each case, the invisibility of formulae was caused by a specific edit, the date and time of which I have indicated in a note at the foot of the damaged tasks's discussion page. Hout (talk) 10:45, 24 September 2016 (UTC)

The current list (updated weekly) of damaged and repaired tasks is now at: http://rosettacode.org/wiki/User_talk:Gerard_Schildberger#Restoring_formula_visibility_to_50.2B_tasks_for_Chrome.2C_IE.2FEdge.2C_Safari_etc Hout (talk) 12:39, 7 November 2016 (UTC)

Hi, I've marked few edits in the above list that I've made to fix the math visibility; I'm on Chrome/Win7Pro-SP1 and I see this problem too. -- WillNess (talk) 09:37, 15 October 2016 (UTC)
Thank you ! I've added your repairs to the active list at https://rosettacode.org/wiki/User_talk:Gerard_Schildberger#Restoring_formula_visibility_to_50.2B_tasks_for_Chrome.2C_IE.2FEdge.2C_Safari_etc Hout (talk) 11:59, 15 October 2016 (UTC)

Tasks vs syntax demos - the case of List Comprehensions[edit]

Restored this on the grounds that it matches all three of the stated requirements:

- They should be distinct from (nested) for loops within the syntax of the language. - They should return either a list or an iterator (something that returns successive members of a collection, in order). - The syntax has parts corresponding to that of set-builder notation.

It uses no for loops, returns a list, and has the parts corresponding to set-building notation.

The previous alternative is useful, but is restricted to a smaller subset of JavaScript, and arguably uses for loops.

If we are to delete one, we should delete both, but I am not sure that either approach has much value.

Both examples are illustrative of such resources as JavaScript is currently able to provide for patterns of this kind.

Hi Hout, unfortunately map & filter are the other way of doing things that are not list comprehensions. map&filter are arguably as well known a method as list comprehensions and some languages have both map & filter and list comprehensions as part of the language. The wp:List comprehension article also makes the distinction up front. Maybe I should add that fact to the task? --Paddy3118 (talk) 20:16, 7 September 2015 (UTC)


Clearly JavaScript 1.6 lacks built-in list comprehension syntax, and I understand your point, but this raises the issue of the value and purpose of of the Wiki. I would argue that users of Javascript seeking to solve the kind of problems that are addressed by list comprehension are better served by an example of how the resources of the language can be used than by a blank page.

Deletion might be intelligible if the purpose of the wiki was the support a narrow language partisanships or evangelisms ('my language has better built-in support for this than yours') but not if it is a public resource aiming to help those who look up a particular language under a particular heading.

If we were to delete that example, we would really also have to delete the preceding JavaScript example too (it uses a kind of for loop), and also the Mathematica example which is syntactically and formally identical. I am not sure that a chain of such deletions would really seem particularly constructive and helpful to users.

To concretise, why, for example, should we 'allow' users to find and reflect on the current Mathematica example:

Select[Tuples[Range[100], 3], #1[[1]]^2 + #1[[2]]^2 == #1[[3]]^2 &]

but not line 1 of the second JavaScript example:

select(nTuples(range(1, 100), 3), function ([x, y, z]) {
return x * x + y * y === z * z;
});

These two forms are clearly isomorphic, but more importantly, they are both clearly of relevance and potential interest to users.

Hi Hout. This task is specifically about list comprehensions as a syntactic construct. It could have been about select statements where it would not suffice to get the result using if/elif.../elif/else blocks - again they may be isomorphic as you say but we want the construct asked for not merely a way to get the answer. map& filter can get the result but it is not what is asked for. --Paddy3118 (talk) 21:08, 7 September 2015 (UTC)

I think we need to consult more broadly, to see how widely your understandable but perhaps slightly zealous appetite for deletion is felt to add value, rather than eroding it. Remember that when you asked to be allowed to do this kind of thing in the Discussion page, you were counselled to restrain yourself and restrict your targets to examples which relied on 'for loops'. This is not one of those examples. It uses functional set construction.

Does it use a list comprehension? I think you must agree that it does not. In fact, this: [1] might give Javascript list comprehensions in 2016. If you had an interpreter with the feature you might state that the feature is experimental, give the link and code the task example and run it.
The language spec I guess for now says that list comprehensions are missing but may be on the way. --Paddy3118 (talk) 21:40, 7 September 2015 (UTC)


Yes, it writes a list comprehension, precisely as requested, and precisely in the manner that will be most helpful and instructive to current JavaScript 1.5 and 1.6 users who

1. need to write a list comprehension, 2. want help with writing one in JavaScript, and 3. turn to Rosetta Code for help.

We may still be waiting for syntactic sugar for list comprehensions in JavaScript, but we can write them in any Turing-complete language which supports higher-order functions. All syntax "just rewrites" lambda applications. Even in Haskell the list comprehension syntax desugars down to Haskell's lambda primitives.

The syntax in which I have written that list comprehension is identical to that of the Mathematica example: a boolean lambda applied to a functional set construction, and that is precisely what lies under *all* the various syntactic sugars in which list comprehensions can be written, without nested for loops, in any language in which they can be written, including in JavaScript.

Your proposal would, inadvertently of course, have no other effect than to prevent users of JavaScript from using Rosetta Code to find out how to do that.

Is that really what you want ? I wonder if some slight confusion has arisen in your mind about the nature and structure of compilers and interpreters ?

I think that filter, with an appropriate generator, satisfies the requirements of the list comprehension task. I think that requiring syntax instead would violate the Task focus aspect of Rosettacode. --Rdm (talk) 23:25, 7 September 2015 (UTC)
Hi Rdm, unfortunately at least two sets of language implementors are seen to make the distinction in their language - having first had for-loops and map/filter, then bringing in list-comprehensions as a different syntactic construct at a later date: Python with its list comprehensions (expanded with other comprehensions at later dates), and now Javascript - the language example I am questioning.
The task is about a particular syntactic construct. It does not go against my reading of your reference to Task Focus. Several languages, including popular languages, either already have or are considering adding the construct. The task is written to show those languages that have the construct.
Admitedly we don't have many other tasks about language syntactic features, I have found Flow-control structures, Exceptions, Regular expressions, Loop Structures, Conditional structures, Function definition, and maybe Short circuit evaluation; but just as if a Task asks for a specific algorithm then that algorithm should be used, then I think that if a task asks for a specific syntax then that syntax should be what is shown - this applies especially to Javascript as it is made clear when in the future the construct might be added so telling you that before that date it is yet to be added.
--Paddy3118 (talk) 06:28, 8 September 2015 (UTC)
Why is this unfortunate? Do you think that this concept of "syntactic construct" is about the arrangement of characters used to form it? Or is it about the results which it achieves? --Rdm (talk) 07:34, 8 September 2015 (UTC)

No claim that a Rosetta task is 'about a particular syntactic construct' is consistent with Rosetta Code's editorial terms of reference, or with the unconflicted exercise of editorial impartiality. In combination with undisguised evangelism of particular languages, it risks the appearance of destroying content in the name of over-vigilant gate-keeping. It can not be in the public interest to redefine tasks as exclusive built-in sugar tasting parties, with irritable bouncers at the door.

The Haskell wiki puts it well at https://wiki.haskell.org/Syntactic_sugar

They make that point that syntactic sugarings don't add functionality to a language, they are plain textual replacements for expressions that could also be written in a more analytic way.

Your interpretation that "The task is written to show those languages that have the construct" would imply that certain languages are not invited because equivalent expressions can not be written in them. That is technically quite simply incorrect, it is clearly in violation of Rosetta Code's editorial terms of reference, and it is obviously without value to the public.

Excluding entries which show how equivalent (unsugared) expressions can be written may be consistent with the kind of Pythonic evangelism which you openly admit, but it can not be consistent either with public interest or with the actual technical nature of syntactic sugar.

The entries for languages that have a built in sugar may well be interesting and helpful as demonstrations of a particular idiom, but the entries for languages that lack such sugar are arguably even more interesting as demonstrations of how equivalent expressions can be written when sugar is not provided for free.

If you feel that entries of the latter kind should be deleted, you may have to ask yourself how productively you are able to handle a conflict of roles. Is the quality and impartiality of your editorial work enhanced or diminished by your admitted 'use' of the site for Python evangelism ?

OK, I'll try to be a little more clear as to why I think my edits are justified:
  1. The task is about syntax. Having a list comprehension
  2. ECMA - the standards body for Javascript says that the construct may arrive in 2016 and gives an example of what they think the syntax should be.
  3. You give something other than the ecma proposed standard and argue that it should stand as an example of comprehensions in Javascript.
Your use of the word sugar doesn't mitigate the above points. Your hint that my love of Python :-) is diminishing the quality of my argument would need further explanation - preferably with the regard to the points I have been making here, as I think your mention of Python is spurious.
--Paddy3118 (talk) 07:59, 8 September 2015 (UTC)


I think we can agree to differ and leave it at that. The code and the introductory remarks have now both benefited from your interventions. Thank you for that, and for a stimulating discussion.

The points on which we take different views are perhaps:

  1. The editorial principle of Task focus. Your interpretation that tasks are "about syntax", or "to show languages which have XYZ" seem to me to violate that central principle. A difference of interpretation.
  2. Whether languages which lack a particular syntactic sugar should display blank pages, or should have illustrations of how the task can be achieved by writing an equivalent expression. I take the latter view, you appear to take the former.
  3. Whether ECMA's (welcome) proposal to introduce direct sugaring in the future is of immediate help to current users of existing JavaScript versions. I don't think that distant water relieves immediate thirst. Perhaps you do ? I don't know.

My concern about the notion that an editor can or should see themselves as an "advocate" of a particular language (hammers are "better" than saws ?) arises from your interpretation that it is legitimate to interpret tasks as "written to show those languages that have the construct".

A startling phrase, and one that logically leads (as we have seen) to 'edits' which are actually just wholesale deletions, as if there should be a Python entry in that list, but no entry for the versions of JavaScript that so many people are currently using.

As long as you are not going to attempt a deletion of the (syntactically identical) Mathematica entry too, I think we can leave things as they are and respectfully differ.

You appear to feel that syntactic sugar is just a word. That's fine. I think it's an engineering task (see https://wiki.haskell.org/List_comprehension) and I also think it is the heart of what we are discussing here. We just disagree, that's all.

Let's just set tasks, see how different languages can be used to achieve the same results, and be useful to the public.

No need to drift into this territory: http://www.explainxkcd.com/wiki/index.php/386:_Duty_Calls  :-)

Two formulae invisible in the GAP contribution on Machin-like formulas[edit]

I notice that two of the <math> tagged formulae in the preamble to your GAP contribution:
http://rosettacode.org/wiki/Check_Machin-like_formulas#GAP
are invisible on the majority of browsers. Chrome, IE/Edge, Safari and most other browsers all display the server-side graphic for formulae, and something about two of your <math> tag contents/contexts seems to be tripping the MediWiki HTML generator into producing ill-formed display tags for them (zero image height, because, in each case, of a missing semi-colon between two attribute names);
Perhaps these formulae were originally edited on Firefox, which, (installed fonts permitting) uses local MathML processing rather than displaying the graphic file ?
Iterative experimentation with any of the browsers mentioned above should make it possible to find a representation which is visible both on on the majority of browsers, and on Firefox too. Hout (talk) 13:10, 7 November 2016 (UTC)
Hello. This is valid LaTeX. Do I have to infer that LaTeX is broken in RC? If so, I'll remove every equation I have written in the tasks. I'm not going to try to find what is not broken in the LaTeX renderer to fix the formulas: it's not even able to print "\sin x" in the Opera web browser. FYI, the site http://math.stackexchange.com makes heavy use of MathJaX, and everything is printed correctly in every browser I have tested. Same with Wikipedia: everything looks fine.
Arbautjc (talk) 16:30, 7 November 2016 (UTC)

Faulhaber's formula#Python[edit]

Thanks to have added the note. I don't know how to change the formulas: they involve double sums with tricky indices, and they would hardly be legible as text only. On the other hand, they are not legible at all as is on many browsers. Not satisfying either way. Arbautjc (talk) 22:06, 22 November 2016 (UTC)

Thanks for looking at that – it does seem intractable at the moment, but at least we have pointed people to the possibility of viewing it in Firefox Hout (talk) 22:09, 22 November 2016 (UTC)


Pythonic code[edit]

Hi, You've stated that you don't think PEP-8 applies to your functional code. Have you tried to get PEP-8 updated as yet?

Currently your code adds commentsabove function definitions, where it is "Pythonic" to add such - given your reasons for those comments, to the Python docstring.

The difference is shown here:

In [29]: # concatMap :: (a -> [b]) -> [a] -> [b]
...: def concatMap(f):
...: return lambda xs: list(chain.from_iterable(map(f, xs)))
...:
...:
...: help(concatMap)
Help on function concatMap in module __main__:
 
concatMap(f)
# concatMap :: (a -> [b]) -> [a] -> [b]
 
 
In [30]: def concatMap(f: Callable) -> Callable:
...: """\
...: Returns a function of one argument, a list, that:
...: chains the results of mapping function f over its list argument.
...: """

...: return lambda xs: list(chain.from_iterable(map(f, xs)))
...:
...:
...: help(concatMap)
Help on function concatMap in module __main__:
 
concatMap(f:Callable) -> Callable
Returns a function of one argument, a list, that:
chains the results of mapping function f over its list argument.
 
 
In [31]:

You have the chance to write more Pythonic code but but instead continue to add Haskell translations, under the guise that "Guido hated, and stymied functional programming in Python; and that you know better". Fine, you should put this to the language community and convince them of your superior methods. Until then, Post Python and not converted Haskell. If you haven't converted Guido's community, then its not idiomatic Python.

Paddy3118 (talk) 10:44, 28 October 2018 (UTC)

Functional Python and pythonic Python[edit]

'Pythonic' Python is an excellent subset of Python, well optimised for many purposes, but it is not the Python language itself.

That is right. One can write bad code in any language; Pythonic refers to the communities best attempts at guidelines for writing good Python. Paddy3118 (talk) 16:12, 28 October 2018 (UTC)

Some useful parts of Python, including parts of the language which are well suited, or even essential, to functional programming, lie outside the scope of the Pythonic idiom, which is deliberately optimised for standardisation of imperative programming styles.
Functional programming is a distinct and well-established use of Python. There is an introduction to it in the Python documentation. O'Reilly distributes a book about it. Chapters are devoted to it in other books. There is extensive discussion of it online, and significant use of it in projects.
It is not constructive to attempt to exclude functional Python from Rosetta Code on the grounds that it differs from the Pythonic idiom which (for excellent and understandable reasons) you personally like, respect and use. Others do use, and benefit from using, functional Python.

I don't wish to exclude one of Pythons three main coding styles, and don't seek to. You misrepresent me, deliberately. You act as if all of Pythons good practices are beneath you because functional is best. You substitute your own type comments as comments - no need for docstrings. You create new functions hiding builtins willy-nilly; you create new functions with the same functionality, but different names to standard library functions; In short, you ignore Pythons best practices with the excuse that "it's Python isn't it"?

If your ideas have merit, then you should b able to convince the Python community. That community that built those same libraries and eco-system that you stated you use'. That eco-system exists because of the actions of that community you eschew. Paddy3118 (talk) 16:12, 28 October 2018 (UTC)

You often explain that the notion of 'idiomatic' is central to your own contribution to Rosetta Code. I respect that, and find it entirely understandable. You are an intelligent person, and therefore will also have no difficulty at all in understanding that the goal of the Rosetta project, summarised on the landing page as to demonstrate how languages are similar and different, and to aid a person with a grounding in one approach to a problem in learning another will attract both readers and contributors whose interests have varying balances of emphasis on similarity and difference.
Perhaps you feel that crowds gather around the Rosetta Stone in the British Museum to be inspired and elevated by the exemplary idiomatic purity of its parallel Greek, Demotic and Hieroglyphic texts. If that is your belief, then I am very happy to respect it. No problem at all. The value that I personally attach both to the Rosetta Stone, and to the eponymous Code project, lies, however, in what is shared between languages. Meaning, deep structure, universal functions, shared reducabilty, to the Lambda calculus and the operations of Turing machines. I personally happen to be less interested in the surface phenomena and the differences, but I have no objection whatsoever to others being more preoccupied by difference than by similarity.
It worries you that my functional Python bears some resemblance to Haskell. For me, and, I believe, for some other Rosetta Code readers, that constitutes a virtue – a visible sharing, beyond superficial differences, of deep structure. It can be very instructive to compare the implementations of concatMap, for example, in different languages. The (concat . map) composition itself is not given to us by Haskell. It comes from a much deeper and more interesting level of shared meaning – mathematics, from which in the last analysis, no programming language can successfully escape, or fail to be structured by.

Compare and contrast the rise and fall of the Lisp language. Also said to be based on maths, and originally from academia. Lisp has enriched later languages, but has gone from being "The Next Big Thing", with Lisp processors and Lisp workstations, to its current marginal use. Python has functional programming as one of many styles it supports. It may not have fully embraced functional programming as you would like, but maybe you to are blinded by your "Lisp moment". Paddy3118 (talk) 16:12, 28 October 2018 (UTC)

Two technical points, and then a general one. First – consistent idiom – Our interests in Rosetta Code may diverge in the balance of our emphases on deep and shared versus surface and different, but we do overlap, I think, in feeling that well-linted code has a value. We won't agree on which idiom of Python we find most useful, but we can agree that it is useful to apply linter tools. I apply Linter-flake8, and use AutoPep8, with all my Python code, both for Rosetta, and for my working projects. Let's move on, avoid subjective idiom wars – they seem a slightly silly waste of time – and defer to the tooling.
Second - Semantic type comments I think that the use of informal Hindley-Milner style semantic type comments in my Python code may be near to the heart of your aversion to my functional Python style as 'too Haskell-like' (let's ignore the offensive references to machine translation :-). I find these semantic type annotions very helpful to my planning and reading of code, and perhaps, since we are only talking about comment lines in code, it should really be enough to say that they are useful. But in case it reassures you: (1) the Pep8 linters which I use have no objection to the position of my comment lines, and (2), I am far from alone in using such comments in functional Python, and in functional uses of many other languages outside the family of ML and Haskell. See, for example, some of the slides in this very helpful presentation: https://speakerdeck.com/kachayev/monadic-parsing-in-python

I find these semantic type annotions very helpful to my planning and reading of code, ...
And yet you ignore the Pythonic style of adding them to docstrings or of adapting and using the type annotations that Python has. It looks as if you steamroll your way through that which inconveniences you. Rather than convince the community, you independently profess yourself a special case and that the guidelines don't apply to you. Paddy3118 (talk) 16:12, 28 October 2018 (UTC)

Finally, a suggestion rather than fight for years over whether particular instances of functional Python are 'Pythonic' enough for you, (they are unlikely to be – some central elements of functional programming were deliberately excluded from the Pythonic tent, though the community refused to have them removed from the Python language) let us instead just accept that functional Python, while real, documented, written about and used, is nevertheless distinct from the 'pythonic' Python. I am very happy to go on using PEP8 linters, indeed I think it's a good idea, but why don't we just develop a practice of dividing Python contributions into two subsections: Pythonic and Functional.
Let's stop the silly campaign of attrition though – I believe that the spirit of Rosetta is to be more inspired what is shared than by what is different, and frankly, I begin to feel harassed.

A (repeated) suggestion: If your ideas have merit then you should be able to convince the Python community of its merit. Your style seems singular. Members of the Python community do change the language. What is Pythonic does evolve, but standing on the sidelines shouting "Don't you see"!! might not be the best way to create a change toward your style. Paddy3118 (talk)

Unlike you, it seems, I have no interest whatsoever in converting anybody else's style of programming at all, and I ask you to respect mine. Functional programming is already, and inevitably, a well-established and documented use of the Python language, even if it in some tension with the 'Pythonic' subset of the language (which I am not alone in finding to be better optimised for some contexts and uses than for others).
You appear to be interested in changing my style in a way that you genuinely consider an improvement, and your addition of compiler type-hints was interesting, but also involved deleting important and useful semantic information, written in a format with which many users of functional Python are familiar and actively use (see, for example the presentation on monadic parsing in Python).
Enough now, I respect your beliefs about Python, and I quite understand that they will inform the code which you contribute.
You must however understand, that my use of Python is different, and that it is inappropriate for you to continue to interfere with it in this persistent and intrusive manner. I believe that my regular use of PEP8 linters more than meets the requirements of Rosetta Code, and I know that others feel the same. Hout (talk) 17:10, 28 October 2018 (UTC)

Harass. Defined as "Subject to aggressive pressure or intimidation". I am not being aggressive. I disagree with you - it happens. Intimidation: I don't slap an improve tag on your entry without stating why. Pressure: I am trying to improve your Python; we unfortunately disagree. Paddy3118 (talk) 16:12, 28 October 2018 (UTC)

Paddy or Donald, is not up to you, or indeed a dictionary, to determine whether or not I feel harassed by your behaviour. I do. Enough now. Please be kind enough to desist. We can agree to differ, and the Python language is large and expressive enough for us both to offer alternative solutions within the rich resources of its syntax and libraries, and differing currents and traditions, with the the help of a linter. Thanks. It has been stimulating, but that is more than enough now. Please stop. Hout (talk) 17:10, 28 October 2018 (UTC)
If you don't like my functional Python word-break parsing code, for example, just create a 'Pythonic' sub-header, and contribute a 'version which feels more 'pythonic' to you. No need at all to berate me. A different approach and better version is a much more interesting and constructive mode of criticism. Hout (talk) 12:08, 28 October 2018 (UTC)
Wow. The no-true-Scotsman is thick on the ground. Hey, If Python doesn't want you, come on over to Perl 6. We've quite cheerfully stolen many of the good bits from Haskell and are always happy to see functional implementations of various tasks. (I personally am interested in functional programming, but I suck at it. 🙄) --Thundergnat (talk) 12:52, 28 October 2018 (UTC)
Thanks ! The resources of Perl have found a way through many difficult moments for me (most memorably 4Gb of badly formed CSV files, in which commas sometimes delimited fields, and sometimes just expressed English pauses :-) Python too of course – 4 years later a single 4Gb file of (better formed) CSV was swiftly handled by the Python CSVReader. Fortunately, functional programming remains a well-embedded and well discussed part of Python use, and an unimpeded route to all the Python libraries :-) The community made sure of that ... Hout (talk) 13:02, 28 October 2018 (UTC)
import The Unwritten Rules of Python
1. You do not talk about the GIL.
2. You do NOT talk about the GIL.
3. Don't even mention the GIL. No seriously.
Unlike Perl6, Python uses Reference Counting (like Perl5) not Garbage Collection. Locking the refCount is a major problem when multithreading. Python overcomes this by having a global lock, which effectively means that only one thread can run at any one time. So Python can multithread but only for reasons other than speeding up CPU intensive tasks. If you try running a CPU intensive task across more than one thread it will run about half as fast as single core due to contention for the GIL. You are thus not going to achieve some of the advantage you think you will with functional code in Python
The style you use must be acceptable as it is the method used in Python 1.6 'reduce(lambda x, y: x+y, range(1,101))' was then the way to sum a range. Comprehension was introduced in python2 so perhaps you could mark your examples requires python1.6 and paddy could mark his requires python2.
Some imperative languages eschew Break and Continue. Plaese, please, no seriously please tell me that Sexy_primes#Imperative_.28iffy_.26_loopy.29_Style isn't Pythonic--Nigel Galloway (talk) 13:56, 28 October 2018 (UTC)
Indeed, in fact Python itself is not Pythonic – it contains (and many actively use) reduce, map and filter. There was a move from the ex-BDFL to reduce Python to the Pythonic dialect, but the PEP processes rejected it, and he is, in any case, after other frictions, now gone.
Set comprehensions are exactly the kind of thing that we need – practical and mathematically well-founded enough to inspire complete confidence, as well as powerful and elegant. In the word-break example (and sometimes elsewhere) I have shown the desugared underlying list monad version, not just because it can be interesting or more flexible to understand what's going on under the hood or bonnet, but also because my experience has been that the insight helps my intuition in using even the sugared version (in Python, Haskell or elsewhere) more fluently, and with more clarity. Hout (talk) 14:11, 28 October 2018 (UTC)
On Perl-6 and Haskell I guess TIMTOWTDI + Haskell == TIMTOWTDI, little change.
Pythons idioms are used to allow libraries initially coded in other languages to act like native libraries and datastructures. The Python community believes it makes it easier to use such libraries as they are expected to act similarly and be more easily maintained.
P.S. I genuinely wish Perl-6 good luck (again). If its new ideas gain traction who knows, Python might add a library... :-)
 Paddy3118 (talk) 16:12, 28 October 2018 (UTC)