#Functions may output by calling a callback function or event
Functions may output by calling a callback function or event
The callback function should be inputtedprovided using a valid input method.
Example in JavaScript that outputs Hello world!
:
f=>f("Hello world!")
This may be shorter than returning a value in some languages:
import random as r
def f(x):
q=r.random()
return(q+q/2)/2
As opposed to:
import random as r
def f(x,g):
q=r.random()
g((q+q/2)/2)