Ensure path is shortened correctly
This is to avoid a scenario described by @odeda: Given project based dir ~/doc and a file at ~/documents/foo.txt (a different directory), wouldn't this code cause shortestPath() to return "uments/foo.txt"? This would not be useful.
Please register or sign in to comment