mirror of
https://github.com/lyx0/nourybot.git
synced 2024-11-13 19:49:55 +01:00
22 lines
278 B
Go
22 lines
278 B
Go
package commands
|
|
|
|
import (
|
|
"github.com/lyx0/nourybot/internal/common"
|
|
)
|
|
|
|
func Coinflip() string {
|
|
flip := common.GenerateRandomNumber(2)
|
|
var reply string
|
|
|
|
switch flip {
|
|
case 0:
|
|
reply = "Heads!"
|
|
case 1:
|
|
reply = "Tails!"
|
|
default:
|
|
reply = "Heads!"
|
|
}
|
|
|
|
return reply
|
|
}
|