5 kyu
Lattice Paths, But...?
65Bubbler
Loading description...
Algorithms
Dynamic Programming
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.
Very interesting but you should consider addint the tag
Dynamic Programming
done
Approved
Hi,
Quite interesting. And the more I dig, the more interesting it is.
But I think that you should change a bit your tests. Especially the "disaster" grids are all of the same type and do not help at all to debug the random tests. I made several implementations that all are passing the fixed tests but do not pass the random ones even if they are different. That means your fixed tests are not sufficient and considering the size of the random grid, this is really a pin in the ass: that makes almost impossible to debug the thing! Small grids with special "patterns" would be very helpfull (those that I'm currently searching on my own... ;p )
EDIT: testing for unreachable lower corner would be a good idea too (that can show up in your random tests, even if it's not probable)
Thanks for the detailed feedback.
I'll add small fixed tests with easier-to-see patterns, and some visualization for them as logs. May I look at some of your codes that pass only the fixed tests?
Edit: I updated the test cases with more fixed ones and small random ones. Does it seem better now?
Seems good. I'd suggest 2 more things:
you do not display the grid in all the small tests. That makes it a bit weird. I believe you should display it systematically for the basic, 5x5 (it lacks 2 of them), disaster grids.
if you do not want to add the display in the small random grids too (might be a new kata on it's own, that!), I'd suggest to add those fixed tests too:
about my previous code versions... I do not remember them, sorry... :s (the base was always the same, only the conditions used to update the data changed a bit)
I ended up adding the displaying function in the test script. (it's even longer than my solution to the kata!) Seems like it's getting harder and harder to translate to other languages... :P