Forum de discussion pour l'UE Programmation Fonctionnelle en OCaML

fonction value_at_one , op_prod

fonction value_at_one , op_prod

Mamadou Drame Kalilou írta időpontban
Válaszok szám: 2

bonjour

j'ai pas compris les fonctions value_at_one et op_prod.

j'ai essayé mais j'ai pas pus les faire


merci

bien cordialement

Mamadou Dramé Kalilou

Válasz erre: Mamadou Drame Kalilou

Re: fonction value_at_one , op_prod

Durand Irene írta időpontban
op_prod 1 10 (fun x -> x) (fun x y -> x * y) 1
donnera 1 * 2 * 3 * 4 ... * 10

op_prod 3 10 (fun x -> x * x) (fun x y -> x + y) 0
donnera
3*3 + 4*4 + ... + 10 * 10