ZenScript main repository
您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

functionalInterfaces.zs 259B

1234567891011
  1. //val x = ((a as string) => "hello" + a) as function`auto(a as string) as string`auto;
  2. //invokeFunctional(x);
  3. val y = (a as int, b as int) => a + b;
  4. //invokeFunctionalInt((a, b) => a + b);
  5. invokeFunctionalInt(y);
  6. println(((x as int) => x)(10));