Programming Questions

  • Newest
  • Popular Tags
  • Ask A Question
  • Shortest path challenge test case
    what's the expected result for below test case. ["6","Z","B","C","A","Y","Q","B-C","A-B","A-Z","C-Y","Z-Y","C-Q"] There is no path to traverse from first node 'Z' to last node 'Q'. so returned -1. But its listed in the failed test cases.
    ramireddy posted this question on 11/28/15 | shortest, path
    Answers
  • +
  • 1
  • -
  • 2. z-y, y-c, c-q (the paths go both ways)
  • +
  • 0
  • -
  • Thank you 'torbjornperttu'. Shortest path challenge's description does not state that the connection was bi-directional. So, I was confused.
    Log in to write an answer.