You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
✅ Your code works and matches the specified output for all the test cases.
The input validation and error handling are very thorough.
🚀 Your hot loops are tight and fast.
I measured your program's runtime with my test script. Here are the results:
Test case
Runtime [ms]
Manhattan-testHV1.in
21
Manhattan-testHV2.in
20
Manhattan-testHV3.in
22
Manhattan-testHVD1.in
19
Manhattan-testHVD2.in
548
💡 The way you handle the -d flag at the very top level makes your code clear and easy to reason about, but it also causes some duplication. For example one could argue that two distinct versions of traceback are not strictly necessary.
🤔 One thing to consider is that you could actually process HVD files just fine without the -d flag by treating them as HV files, rather than throw an error. However, I can see why you chose to make the error explicit.
😆 I really liked your hidden fun fact.
Overall a very clean solution.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Please review :)