// 定义函数 def sum(int a, int b) { return a + b } // 调用函数 $console.log(sum(1, 2))