RosettaCodeData/Task/Inverted-syntax/Mercury/inverted-syntax-2.mercury

9 lines
186 B
Plaintext

:- func example(int) = string.
example(N) = S :-
from_int(N) = S0,
pad_left(S0, '0', 3, S).
example(N) = S :-
pad_left(S0, '0', 3, S),
from_int(N) = S0.