ML: Calculer la somme des élément d’une liste

fun sum_list([])= 0
| sum_list(list) =
case list of
[]=>0
|x’::list’ => x’+sum_list(list’)

Comments are closed.