mirror of
https://github.com/correl/elm.git
synced 2024-11-26 03:00:06 +00:00
10 lines
138 B
Elm
10 lines
138 B
Elm
|
module Grains exposing (..)
|
||
|
|
||
|
|
||
|
square : Int -> Maybe Int
|
||
|
square n =
|
||
|
if n < 1 then
|
||
|
Nothing
|
||
|
else
|
||
|
Just <| 2 ^ (n - 1)
|