main_marking4/knight3_test9.scala
changeset 463 0315d9983cd0
parent 424 daf561a83ba6
equal deleted inserted replaced
462:34feeb53c0ba 463:0315d9983cd0
    21   case x::Nil => true
    21   case x::Nil => true
    22   case x::y::p => 
    22   case x::y::p => 
    23     if (legal_moves_urban(dim, p, y).contains(x)) correct_urban(dim)(y::p) else false
    23     if (legal_moves_urban(dim, p, y).contains(x)) correct_urban(dim)(y::p) else false
    24 }
    24 }
    25 
    25 
       
    26 import scala.concurrent._
       
    27 import scala.concurrent.duration._
       
    28 import ExecutionContext.Implicits.global
       
    29 import scala.language.postfixOps 
       
    30 
       
    31 lazy val f = Future {
    26 
    32 
    27 val ts70_urban = tour_on_mega_board(70, List((0,0))).get
    33 val ts70_urban = tour_on_mega_board(70, List((0,0))).get
    28 assert(correct_urban(70)(ts70_urban) == true)
    34 assert(correct_urban(70)(ts70_urban) == true)
       
    35 }
    29 
    36 
       
    37 Await.result(f, 32 second)
       
    38