first commit
This commit is contained in:
9
guessing-game/src/guessing_game.gleam
Normal file
9
guessing-game/src/guessing_game.gleam
Normal file
@@ -0,0 +1,9 @@
|
||||
pub fn reply(guess: Int) -> String {
|
||||
case guess {
|
||||
i if i < 41 -> "Too low"
|
||||
i if i > 43 -> "Too high"
|
||||
41 | 43 -> "So close"
|
||||
42 -> "Correct"
|
||||
_ -> "WAT"
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user