Function definition: Difference between revisions
Content added Content deleted
imported>Joeypas (Added section for ziglang) |
|||
Line 3,674: | Line 3,674: | ||
pop bc |
pop bc |
||
ret</syntaxhighlight> |
ret</syntaxhighlight> |
||
=={{header|zig}}== |
|||
<syntaxhighlight lang="zig">fun multiply(x: i64, y: i64) i64 { |
|||
return x * y; |
|||
} |
|||
//example call |
|||
const x: i64 = 4; |
|||
const y: i64 = 23; |
|||
_ = multipy(x, y); // --> 93</syntaxhighlight> |
|||
=={{header|zkl}}== |
=={{header|zkl}}== |