Timeline for Yahtzee Small Straight Detection
Current License: CC BY-SA 3.0
10 events
when toggle format | what | by | license | comment | |
---|---|---|---|---|---|
Mar 9, 2016 at 1:16 | comment | added | CalculatorFeline |
"F" can be replaced with ""
|
|
Mar 8, 2016 at 20:36 | history | edited | Dave the Sax | CC BY-SA 3.0 |
added 56 characters in body
|
Mar 8, 2016 at 20:20 | comment | added | Darrel Hoffman | The exact input format on PPCG is usually left up to the programmers. Certainly many (probably most) of the answers on here would fail if they were required to use the input format exactly as given. Oh, and nobody is expecting code-golf to be 100% standards-compliant. If it compiles and produces correct output, it's good enough. | |
Mar 8, 2016 at 20:14 | history | edited | Dave the Sax | CC BY-SA 3.0 |
added 1 character in body
|
Mar 8, 2016 at 20:14 | comment | added | Dave the Sax |
The testcases as given include square brackets, spaces and commas, which would cause UB at c[v[i]-'1']++ . Thought I might get flamed for voiding main. Still, I could still shave 21 bytes off with the other changes.
|
|
Mar 8, 2016 at 20:11 | review | Low quality posts | |||
Mar 8, 2016 at 20:26 | |||||
Mar 8, 2016 at 20:08 | history | edited | Dave the Sax | CC BY-SA 3.0 |
deleted 8 characters in body
|
Mar 8, 2016 at 15:48 | comment | added | Darrel Hoffman |
Lots of extra stuff here you don't need. That whole if statement for error-checking isn't necessary, as we can assume the input is valid. Also, you only need to output a "truthy" or "falsey" value, you don't need to literally print the words "TRUE" or "FALSE". A simple 1 or 0 would suffice. The return statement is also not needed.
|
|
Mar 7, 2016 at 23:24 | review | Low quality posts | |||
Mar 7, 2016 at 23:36 | |||||
Mar 7, 2016 at 23:01 | history | answered | Dave the Sax | CC BY-SA 3.0 |