Jump to content

First-class functions: Difference between revisions

m
→‎firstclass.m: Corrected composition order.
(→‎{{header|Nemerle}}: Added a Mercury implementation.)
m (→‎firstclass.m: Corrected composition order.)
Line 892:
apply([], A, Results) :- Results = A.
apply([F, R|Functions], A, Results) :-
apply(Functions, [compose(FR, RF, 0.5) | A], Results).
apply([_], _, _) :- throw("This can't happen!").</lang>
 
Cookies help us deliver our services. By using our services, you agree to our use of cookies.