RosettaCodeData/Task/Function-definition/Nemerle/function-definition.nemerle

6 lines
223 B
Plaintext

public Multiply (a : int, b : int) : int // this is either a class or module method
{
def multiply(a, b) { return a * b } // this is a local function, can take advantage of type inference
return multiply(a, b)
}