main_solution4/knight3.scala
changeset 400 e48ea8300b2d
parent 379 5616b45d656f
child 418 fa7f7144f2bb
equal deleted inserted replaced
399:b17a98b0c52f 400:e48ea8300b2d
     1 // Part 3 about finding a single tour using the Warnsdorf Rule
     1 // Part 3 about finding a single tour using the Warnsdorf Rule
     2 //=============================================================
     2 //=============================================================
     3 
     3 
     4 object CW9c { // for preparing the jar
     4 object M4c { // for preparing the jar
     5 
     5 
     6 type Pos = (Int, Int)
     6 type Pos = (Int, Int)
     7 type Path = List[Pos]
     7 type Path = List[Pos]
     8 
     8 
     9 
     9 
    59 
    59 
    60 def tour_on_mega_board(dim: Int, path: Path) =
    60 def tour_on_mega_board(dim: Int, path: Path) =
    61   time_needed(ttour_on_mega_board(dim: Int, path: Path))
    61   time_needed(ttour_on_mega_board(dim: Int, path: Path))
    62 
    62 
    63 
    63 
    64 
    64 // testcases
       
    65 //print_board(70, tour_on_mega_board(70, List((0, 0))).get)
    65 
    66 
    66 }
    67 }