Beta
Rational Zeros
13jfellows
Loading description...
Algorithms
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.
Solution setup missing import for
Fraction
Tests need updating to use new framework etc.
Very nice idea!!
But since Python has support for it, the output should a list of
rationals
It was a really nice kata. Unfortunately, the author hasn't been around since December 2022. I could change the output type from
float
toFraction
, but it would invalidate all existing five solution (including the author's). I'm not sure what the best way to proceed is.Just my opinion, but given such low solve count (and the fact it's still in Beta) I'd suggest to apply this change, and leave a comment under each solution to notify and encourage them to re-submit.
I agree with your suggestion. I've now changed the output type, updated the description, and notified the three authors whose solutions were invalidated.
Technically, the kata is now ready to be approved, but perhaps we should wait for a few more solutions and rank votes. Average assessed rank is
4kyu
, but one could argue that the handling of root multiplicities pushes this closer to3kyu
territory.It should be mentioned in the description that you may need to include the same zero multiple times in the result. I assume the task was just to find rational zeros, without caring for their multiplicities.
I fixed the description to reflect this requirement.
Just getting started, but I did not see a mention of what degree the polynomials would be. I assume only deg <= 2 by the test cases?
1/7
, or something like50/1001
)[0,0,1]
)Added random tests with more complicated rational roots and a more complex multiplicity test (the random tests also include examples with complex multiplicities)