core_testing2/docdiff_test2.scala
author Christian Urban <christian.urban@kcl.ac.uk>
Thu, 02 Nov 2023 12:37:58 +0000
changeset 473 ac79c2e534bd
parent 401 9471c3b7ea02
permissions -rw-r--r--
updated
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
211
092e0879a5ae updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     1
473
ac79c2e534bd updated
Christian Urban <christian.urban@kcl.ac.uk>
parents: 401
diff changeset
     2
def urbanmain() = {
ac79c2e534bd updated
Christian Urban <christian.urban@kcl.ac.uk>
parents: 401
diff changeset
     3
  import C2._
211
092e0879a5ae updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     4
473
ac79c2e534bd updated
Christian Urban <christian.urban@kcl.ac.uk>
parents: 401
diff changeset
     5
  assert(occurrences(List("a", "b", "b", "c", "d")) == Map("a" -> 1, "b" -> 2, "c" -> 1, "d" -> 1))
ac79c2e534bd updated
Christian Urban <christian.urban@kcl.ac.uk>
parents: 401
diff changeset
     6
  assert(occurrences(List("d", "b", "d", "b", "d")) == Map("d" -> 3, "b" -> 2))
ac79c2e534bd updated
Christian Urban <christian.urban@kcl.ac.uk>
parents: 401
diff changeset
     7
}