Function definition: Difference between revisions

no edit summary
No edit summary
No edit summary
Line 638:
<lang smalltalk>|mul|
mul := [ :a :b | a * b ].</lang>
 
=={{header|SNOBOL4}}==
<lang snobol4> define('multiply(a,b)') :(mul_end)
multiply multiply = a * b :(return)
mul_end
* Test
output = multiply(10.1,12.2)
output = multiply(10,12)
end</lang>
 
Output
123.22
120
 
 
=={{header|SNUSP}}==
Anonymous user