in reply to Re^5: LeetCode Problem #1 - Two Sum - Improve and/or discuss.
in thread LeetCode Problem #1 - Two Sum - Improve and/or discuss.
In "Re: LeetCode Problem #1 - Two Sum - Improve and/or discuss.", you wrote:
"... you have to also allow the reverse order in your tests."
In "Re^2: LeetCode Problem #1 - Two Sum - Improve and/or discuss.", I replied to that saying that I agreed and that the spec had indeed said "any order". I changed @tests to include "any order".
In "Re^3: LeetCode Problem #1 - Two Sum - Improve and/or discuss.", you replied to that:
"not sure why you are duplicating the tests ... (?)"
There were no duplicates. I added (different) tests such that the result could be in "any order".
In "Re^5: LeetCode Problem #1 - Two Sum - Improve and/or discuss.", to which I'm now replying, you've removed the tests that allowed the results to be in "any order". You've modified is_deeply such that any additional tests added to @tests must have the results in ascending order for the is_deeply test to be successful. I do not agree that this is any sort of improvement; in fact, I'd consider it to be a bad move.
By the way, I don't see any difference between my &sort_arrayref and yours. I've looked closely at both; do let me know if I've missed something.
— Ken
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^7: LeetCode Problem #1 - Two Sum - Improve and/or discuss.
by LanX (Saint) on Jan 24, 2022 at 22:13 UTC | |
by kcott (Archbishop) on Jan 25, 2022 at 01:17 UTC |