core_testing2/docdiff_test2.scala
author Christian Urban <christian.urban@kcl.ac.uk>
Fri, 26 Apr 2024 17:35:36 +0100
changeset 486 9c03b5e89a2a
parent 473 ac79c2e534bd
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
}