Greatest element of a list: Difference between revisions
Content deleted Content added
m →{{header|PostScript}}: added works with |
→{{header|Euphoria}}: example edited to be compatible with the earlier versions of Euphoria |
||
Line 354:
=={{header|Euphoria}}==
Applying a function to each element of an array
<lang Euphoria>function aeval( sequence sArr, integer id )
end function
object biggun
function biggest( object elem )
end function
biggun = 0
object a
printf( 1, "%d\n", biggun )
sequence s
biggun = "ant"
a = aeval( s, routine_id("biggest") )
printf( 1, "%s\n", {biggun} )</lang>
Output:
<pre>
1234
|