marking1/collatz_test1.scala
author Christian Urban <urbanc@in.tum.de>
Sat, 17 Nov 2018 22:39:02 +0000
changeset 210 63a1376cbebd
parent 158 94b11ac19b41
child 266 ca48ac1d3c3e
permissions -rw-r--r--
updated
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
158
94b11ac19b41 updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     1
94b11ac19b41 updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     2
210
63a1376cbebd updated
Christian Urban <urbanc@in.tum.de>
parents: 158
diff changeset
     3
assert(collatz(1) == 0)
63a1376cbebd updated
Christian Urban <urbanc@in.tum.de>
parents: 158
diff changeset
     4
assert(collatz(6) == 8)
63a1376cbebd updated
Christian Urban <urbanc@in.tum.de>
parents: 158
diff changeset
     5
assert(collatz(9) == 19)
63a1376cbebd updated
Christian Urban <urbanc@in.tum.de>
parents: 158
diff changeset
     6
assert(collatz(9000) == 47)
158
94b11ac19b41 updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     7
94b11ac19b41 updated
Christian Urban <urbanc@in.tum.de>
parents:
diff changeset
     8