Generating a list of powers in Elm up to some limit
Why don't you just use the exponentiation (^) operator? Using that you can omit the recursion at all:

powers : Int -&gt; Int -&gt; Result String (List Int)
powers base limit =
    if base &lt; 0 then
        Err "negative base"
    else
        let size = floor (logBase (toFloat base) (toFloat limit))
        in Ok (List.map (\i -&gt; base ^ i) (List.range 0 size))


There are some functions I used here:


logBase calculates the logarithm of a number with a given base. This can help to calculate the size of the returned list.
List.range : Int -&gt; Int -&gt; List Int generates an Int list where every element increasing by one.