我在OCaml的程序中有一个错误,我正在寻求帮助.
错误:
This expression has type unit but an expression was expected of type int
包含错误的行错误 soma = soma
let soma = 0;;
let rec nBell n = 
if n == 0 then 1 
    else
        for k=0 to n-1 do 
        soma = soma + ((fact(n-1)/(fact(k)*fact((n-1)-k))) * nBell(k));
            done;;`
谁能帮我?
ocaml ×1