core_templates1/collatz.scala
author Christian Urban <christian.urban@kcl.ac.uk>
Tue, 08 Nov 2022 18:35:41 +0000
changeset 434 8c5804b2f9d2
parent 430 274c865b3878
child 470 86a456f8cb92
permissions -rw-r--r--
updated

// Core Part 1 about the 3n+1 conjecture
//============================================

object C1 {

// ADD YOUR CODE BELOW
//======================


//(1) 
def collatz(n: Long) : Long = ???


//(2) 
def collatz_max(bnd: Long) : (Long, Long) = ???

//(3)
def is_pow_of_two(n: Long) : Boolean = ???

def is_hard(n: Long) : Boolean = ???

def last_odd(n: Long) : Long = ???

}