Here is an example I wrote that uses if-else
branches and guard expressions. When is one more appropriate over the other? The main reason I want to know this is because languages typically have a idiomatic way of doing things.
test1 a b =
if mod b 3 ≡ 0 then a + b
else if mod b 5 ≡ 0 then a + b
else a
test2 a b
| mod b 3 ≡ 0 = a + b
| mod b 5 ≡ 0 = a + b
| otherwise = a