Function definition: Difference between revisions
Content added Content deleted
Langurmonkey (talk | contribs) |
(PascalABC.NET) |
||
Line 2,839: | Line 2,839: | ||
After a <tt>function</tt> has been activated, there must have be ''exactly one'' assignment to the (implicitly declared) variable bearing the same name as of the function. |
After a <tt>function</tt> has been activated, there must have be ''exactly one'' assignment to the (implicitly declared) variable bearing the same name as of the function. |
||
Many processors do not comply with this specification, though, and allow ''overwriting'' the return value ''multiple'' times. |
Many processors do not comply with this specification, though, and allow ''overwriting'' the return value ''multiple'' times. |
||
=={{header|PascalABC.NET}}== |
|||
<syntaxhighlight lang="delphi"> |
|||
function multiply(a,b: real): real := a + b; |
|||
</syntaxhighlight> |
|||
=={{header|Perl}}== |
=={{header|Perl}}== |