Ejemplo n.º 1
0
 private static bool redundantConnectionTest2()
 {
     int[] solution = RedundantConnection.compute(new int[, ] {
         { 1, 2 }, { 2, 3 }, { 2, 4 }, { 4, 5 }, { 5, 2 }
     });
     return(solution.SequenceEqual(new int[] { 5, 2 }));
 }
Ejemplo n.º 2
0
 private static bool redundantConnectionTest1()
 {
     int[] solution = RedundantConnection.compute(new int[, ] {
         { 1, 2 }, { 1, 3 }, { 2, 3 }
     });
     return(solution.SequenceEqual(new int[] { 2, 3 }) || solution.SequenceEqual(new int[] { 1, 3 }));
 }