GATE Computer ScienceVery hardGATE CS (PYQ pattern)

Five cities have symmetric distances d(0,1) = 9, d(0,2) = 14, d(0,3) = 23, d(0,4) = 17, d(1,2) = 11, d(1,3) = 19, d(1,4) = 26, d(2,3) = 8, d(2,4) = 21, d(3,4) = 6. What is the length of the shortest tour that visits every city once and returns to the start?

  1. A. 47
  2. B. 63
  3. C. 51
  4. D. 67

Correct answer: C. 51

Held–Karp (or checking all 12 distinct tours) gives 51 for 0-1-2-3-4-0 (9 + 11 + 8 + 6 + 17). The next shortest tours have lengths 63, 67 and 69.

More Algorithms questions

Exams that ask this topic