Beta

The Seven Bridges of Königsberg

Description
Loading description...
Graph Theory
Fundamentals
Discrete Mathematics
Algorithms
  • Please sign in or sign up to leave a comment.
  • saudiGuy Avatar

    Python new test framework should be used (Refer this for more detail)

  • mauro-1 Avatar

    Description says "a walk that crosses all of the bridges once and only once"

    Tests check "a walk that crosses all of the bridges once and only once and visits all land masses"

  • chelast55 Avatar

    Sometimes some of the random test cases claim to have neither a circuit or path, but in reality do actually have a path (at least that's how testing the particular graph on paper turned out for me). I tried to find a pattern, but I couldn't. It might very well be my code that's bugged here and I could totally have messed up when figuring out the graph on paper, but maybe you should have another look on the randomized tests.

  • Voile Avatar

    Needs random tests.

    • LesterJones Avatar

      Random tests added. That's my first attempt at implementing random testing. So, fingers crossed.

    • LesterJones Avatar

      Also, I am struggling with stopping user modified inputs. Do you have any suggestions?

    • B1ts Avatar

      Copy the array before passing it to solution, and preferrably compute the expected result first, before sending the array to user's function. (for python smth like copy = arr[:] should do the trick)