marking3/knight2_test6.scala
author Christian Urban <christian.urban@kcl.ac.uk>
Mon, 07 Dec 2020 01:25:41 +0000
changeset 383 c02929f2647c
parent 331 e3878cdd38bc
permissions -rw-r--r--
updated
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
331
e3878cdd38bc updated
Christian Urban <urbanc@in.tum.de>
parents: 258
diff changeset
     1
import CW8b._
258
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     2
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     3
assert(ordered_moves(8, List((3,4), (3,2)), (1, 3)) == List((0,1), (0,5), (2,1), (2,5)))
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     4
assert(ordered_moves(8, List((4,0)), (0,0)) == List((2,1), (1,2)))
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     5
assert(ordered_moves(8, List((0,4)), (0,0)) == List((1,2), (2,1)))
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     6
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     7
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     8
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     9
/*
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    10
import scala.concurrent._
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    11
import scala.concurrent.duration._
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    12
import ExecutionContext.Implicits.global
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    13
import scala.language.postfixOps 
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    14
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    15
lazy val f = Future {
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    16
}
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    17
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    18
Await.result(f, 120 second)
ebe71908b13e updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
    19
*/