6 kyu
Even Odd Pattern #1
319 of 736debri
Loading description...
Logic
Arrays
Mathematics
Puzzles
View
This comment has been reported as {{ abuseKindText }}.
Show
This comment has been hidden. You can view it now .
This comment can not be viewed.
- |
- Reply
- Edit
- View Solution
- Expand 1 Reply Expand {{ comments?.length }} replies
- Collapse
- Spoiler
- Remove
- Remove comment & replies
- Report
{{ fetchSolutionsError }}
-
-
Your rendered github-flavored markdown will appear here.
-
Label this discussion...
-
No Label
Keep the comment unlabeled if none of the below applies.
-
Issue
Use the issue label when reporting problems with the kata.
Be sure to explain the problem clearly and include the steps to reproduce. -
Suggestion
Use the suggestion label if you have feedback on how this kata can be improved.
-
Question
Use the question label if you have questions and/or need help solving the kata.
Don't forget to mention the language you're using, and mark as having spoiler if you include your solution.
-
No Label
- Cancel
Commenting is not allowed on this discussion
You cannot view this solution
There is no solution to show
Please sign in or sign up to leave a comment.
This comment has been hidden.
You can check the tags of a kata before trying it. The ones tagged "Puzzles" often require some guessing and trial and error. Not everyone likes these kinds of challenges, so it's ok if you want to avoid them.
Please don't give hints in the comments of puzzle challenges.
My apologies. I hadn't realised there was that tag.
RISCV Translation
I'm working in C, and the random tests seem broken.
but then
And again with a completely different approach that also seems to work:
Trying again several times eventually got me past it.
Fixed the RTG, thanks.
P.S. I failed to notice the much older issue below by @akar-0 when I opened the same issue last night.
thanks for this comment
python new test framework is required. updated in this fork
Approved
Ruby 3.0 should be enabled.
Enabled in this fork
Very interesting as a one liner. Thanks!
This comment has been hidden.
The random tests no longer incorrectly supply what would amount to an attempt at an "empty array" in C.
its unclear.is it a proraming or a riddle chalange ? and shouldnt it be about programing /coding? instead of guessing stuff?
This comment has been hidden.
I second this. At least the second part.
Not too bad, too me like 5-10 minutes before figuring it out based on the actual test cases :D
Not interesting. Guessing it didn't make fun for me. With Lagrange polynomial, it's always possible to find coefficients.
I am still guessing :P
This comment has been hidden.
This comment has been hidden.
Would be helpful to have some test cases with 4 and 5 length arrays.
Totally agree. I ended up giving up on this after hours of trying to track the pattern in the long example... it's not ADHD-friendly.
No example test cases in JavaScript. You could add at least the ones from the description.
already provided
Uppercase function names are usually only meant for constructors.
evenOdd
would be more idiomatic JavaScript.Agree
Translated into both Ruby and Python (I thought I had to use more than one line with this language, but I got over it) :)
I see you are improving with your tests: keep up the good work :)
Tq:)
May I remind you also about translations in this, this and this kata :)?
Also: random test cases added to the JS version too :)