I have the following code:
def myfunct(n: Int, steps: Int) = n match {
case 1 => steps
case (x) => if (x % 2 == 0) ...
In any case, do you need to move the logic with an even number to the register? Do I need a case class?
For instance:
def myfunct(n: Int, steps: Int) = n match {
case 1 => steps
case (even number??) => ...
source
share