pre_marking2/docdiff_test2.scala
changeset 382 1bd800376e0c
parent 323 1f8005b4cdf6
equal deleted inserted replaced
381:116fa3c8584f 382:1bd800376e0c
       
     1 
       
     2 import CW7a._
       
     3 
       
     4 assert(occurrences(List("a", "b", "b", "c", "d")) == Map("a" -> 1, "b" -> 2, "c" -> 1, "d" -> 1))
       
     5 
       
     6 assert(occurrences(List("d", "b", "d", "b", "d")) == Map("d" -> 3, "b" -> 2))
       
     7 
       
     8 assert(occurrences(List("b", "b", "b", "b", "b")) == Map("b" -> 5))
       
     9 
       
    10 assert(occurrences(Nil) == Map())