mirror of
https://gitlab.com/EternalWanderer/dice-roller.git
synced 2024-11-28 21:03:51 +01:00
Fixed formatting bug
Printing an int where not desired.
This commit is contained in:
parent
9142a36897
commit
2ce1e8607e
|
@ -3,6 +3,7 @@ package Coin
|
||||||
import (
|
import (
|
||||||
"fmt"
|
"fmt"
|
||||||
"math/rand"
|
"math/rand"
|
||||||
|
"strings"
|
||||||
"time"
|
"time"
|
||||||
|
|
||||||
"github.com/fatih/color"
|
"github.com/fatih/color"
|
||||||
|
@ -40,7 +41,7 @@ func Toss(castAmount int) {
|
||||||
if castAmount > 1 {
|
if castAmount > 1 {
|
||||||
color.Yellow("Tossing %d coins...\n", castAmount)
|
color.Yellow("Tossing %d coins...\n", castAmount)
|
||||||
} else {
|
} else {
|
||||||
color.Yellow("Tossing coin...\n", castAmount)
|
color.Yellow("Tossing coin...\n")
|
||||||
}
|
}
|
||||||
fmt.Println(fmt.Sprint(coins))
|
fmt.Println(strings.Trim(fmt.Sprint(coins), "[]"))
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in a new issue