Talk:Determine if a string is collapsible: Difference between revisions

From Rosetta Code
Content added Content deleted
Line 34: Line 34:
Good question, and that "determine if" thematic framing of the task inevitably produces clear expectations of a String -> Bool predicate, returning True or False for a given string.
Good question, and that "determine if" thematic framing of the task inevitably produces clear expectations of a String -> Bool predicate, returning True or False for a given string.


That expectation is then lead completely astray into open fields, where no mention of any kind of test or predicate can actually be found in the detail of the sub-tasks [[User:Hout|Hout]] ([[User talk:Hout|talk]]) 14:39, 8 June 2020 (UTC)
That expectation is then lead completely astray into open fields, where no mention of any kind of test or predicate can actually be found in the detail of the sub-tasks. [[User:Hout|Hout]] ([[User talk:Hout|talk]]) 14:39, 8 June 2020 (UTC)

To put it another way, the title suggests writing an testing something like this:
<pre>containsConsecutivelyRepeatedCharacters :: String -> Bool
containsConsecutivelyRepeatedCharacters = (>) . length <*> (length . group)</pre>

and the tasks describe something quite different. A (String -> String) function which defines a new string but 'determines' nothing. [[User:Hout|Hout]] ([[User talk:Hout|talk]]) 14:48, 8 June 2020 (UTC)

Revision as of 14:48, 8 June 2020

Harry S Truman

Yes, Truman's middle name is   S   with no period,   even though President Truman most often signed his correspondence with a period after the   S.     -- Gerard Schildberger (talk)

How strict are the requirements?

If somebody posts an example that works correctly, but doesn't use the 5 required example strings from the task description, should the entry be marked incorrect? --Thundergnat (talk) 01:52, 29 November 2019 (UTC)

As the author of the task being mentioned,   I'd mark it (somehow) as missing some of the required output   (like a modified   {{output?}}   template).   If there were an   incomplete output   (or other such wording) type of flag,   that would be usable/noticeable,   and   if   it got the attention of author of that programming entry.   Another possibility is the   {{needs improvement}}   template,   but that (I think) conveys that the program entry is to be improved.   But I guess what needs improvement is kinda up to whatever needs to be improved.   Some programs have the input(s) either within (inside) the program as statements or literal fields, or made available via parameters, or other (such as an input file).     -- Gerard Schildberger (talk) 04:42, 29 November 2019 (UTC)
An   incomplete output   (flag) template may not have the wording (and color) to convey the message that only   some   of the output is missing.     -- Gerard Schildberger (talk) 04:42, 29 November 2019 (UTC)
I'm not exactly sure what the word   strict   means in this context.   If the entry works correctly, but has no output at all, would that be sufficient grounds to flag the example/entry?   Or if only half (or some other fraction) of the output was shown, or another completely set of output   (albeit correct).   You ask to see 20   funny-bunny primes,   but I only show 10.   (I think those primes hippty-hop around).   Or worse yet, the output is somewhere else entirely   ---   such as a different page on some another website   (that also leaves cookies on the viewer's computer   ...   ugh).     As I understand it, it would.   But how does one who doesn't know the programming language well enough to know that the computer program works correctly, if all I have to judge its correctness is the output of that program?   I believe that is, in essence, the basis of (or for) flagging a programming entry.   If I know the programmer well enough, and if I think/know the programmer is conscientious enough, I'll sometimes enter a new talk topic on the programmer's user talk page.   -- Gerard Schildberger (talk) 04:42, 29 November 2019 (UTC)
Note that this Rosetta Code task says to use (at least) these/those five required examples.   It was my intent to not limit whatever examples to be used,   but to have a common base of output for comparisons (among the various computer programming language entries).   I must admit, I don't know of all the possible templates that are available and/or what is usable for such a purpose,   as some templates do more than others   --- such as adding an language entry to some category that can be examined later by reviewing a specific category of that computer programming language.   The template   {{improve}}   could be used as it comes close to what I intended to express.   The template   {{output?/beta}}   is another possibility,   but I don't know exactly what that's used for.     -- Gerard Schildberger (talk) 04:42, 29 November 2019 (UTC)

I'm not exactly sure what the word 'strict means in this context.

Hmm. Let me see if I can clarify. If somebody posts an example that works correctly, but doesn't use the 5 required example strings from the task description, should the entry be marked incorrect? Nope; can't make it any clearer than that. Ok. I'm going to assume from your rambling exposition that if somebody posts an example that works correctly, but doesn't use the 5 required example strings from the task description, it should be marked incomplete. Will do. --Thundergnat (talk) 14:58, 29 November 2019 (UTC)
This task requirements explicitly states to use the (following) five test strings (at least),   it didn't mention any others that had to be used.   Nowhere does the task requirements require that one has to use the string(s) that were used as examples shown in the task's preamble   (but you are free to use them as well if you want, along with any others that you want).   If you are misunderstanding or misreading the task's requirements, please re-read what is in the task requirements section.   If there is a problem of understanding or interpreting the task's requirements, this is the place to work it out.   It would also help to state specifically what example(s) you think weren't used by the REXX's entry from those five specifically mentioned in the task's requirements.   Please note that the REXX example did use the five test strings as per the task's requirements.   Also, please refrain from posting your categorizations of someone else's comments,   this is becoming somewhat rash and not what I expect from people using Rosetta Code.   If anything, I was hoping that some of the concerns I raised would discussed or even addressed.     -- Gerard Schildberger (talk) 17:29, 29 November 2019 (UTC)

<Gerard>: This task requirements explicitly states to use the (following) five test strings (at least),

<thundergnat>: If somebody posts an example that works correctly, but doesn't use the 5 required example strings from the task description, should the entry be marked incorrect?

<Gerard>: removed bogus flagging as all five strings were indeed used...

<Gerard>:(later) corrected an input field string in the program...

As it turns out the required five strings were not used. My marking the entries incomplete was not wrong despite your disparaging comments when you removed the "incorrect" markup. But somehow it is I that is made out to be the uncivil one. Pot, let me introduce you to kettle. --Thundergnat (talk) 21:41, 29 November 2019 (UTC)
I've just had a look at it and the problem seems to be that the third example string should end with "7777888" but the corresponding example in the REXX entry ends with "77788". The 'squeezable' task has a similar discrepancy. --PureFox (talk) 18:18, 29 November 2019 (UTC)
Thank you so much for that information.   I looked at that (REXX) output quite a few times and didn't see it.   It's amazing what a good pair of eyeballs does to defuse this situation.   I'll fix it them ASAP.     -- Gerard Schildberger (talk) 18:37, 29 November 2019 (UTC)

What does determine mean?

As the task is titled 'Determine if a string is collapsible' should there not be a non-collapsible example?--Nigel Galloway (talk) 14:07, 8 June 2020 (UTC)

Good question, and that "determine if" thematic framing of the task inevitably produces clear expectations of a String -> Bool predicate, returning True or False for a given string.

That expectation is then lead completely astray into open fields, where no mention of any kind of test or predicate can actually be found in the detail of the sub-tasks. Hout (talk) 14:39, 8 June 2020 (UTC)

To put it another way, the title suggests writing an testing something like this:

containsConsecutivelyRepeatedCharacters :: String -> Bool
containsConsecutivelyRepeatedCharacters = (>) . length <*> (length . group)

and the tasks describe something quite different. A (String -> String) function which defines a new string but 'determines' nothing. Hout (talk) 14:48, 8 June 2020 (UTC)