summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrandon C. Irizarry <brandon.irizarry@gmail.com>2026-04-23 16:42:37 -0400
committerBrandon C. Irizarry <brandon.irizarry@gmail.com>2026-04-23 16:42:37 -0400
commit3866d339a193146b02e1ad6e94a59b323a9761f5 (patch)
treea272c2515c6c280caad7802319841ba73074d8e0
parentd997dfc6b7235c49c29cfb19762f496e8fcacb10 (diff)
feat: clarify the printouts
-rw-r--r--main.go4
1 files changed, 2 insertions, 2 deletions
diff --git a/main.go b/main.go
index 92e9b22..f4b837b 100644
--- a/main.go
+++ b/main.go
@@ -56,14 +56,14 @@ func game(numPlayers, faces int) {
for {
score++
outcome := throwDie(faces)
- fmt.Printf("Player %d threw a %d\n", id, outcome)
if outcome == winningNumber {
- fmt.Printf("Player %d threw the winning number! Their score is %d\n", id, score)
+ fmt.Printf("Player %d threw a %d: the winning number! Their score is %d\n", id, winningNumber, score)
finishedPlayers <- Player{id: id, score: score}
return
}
+ fmt.Printf("Player %d threw a %d\n", id, outcome)
time.Sleep(1 * time.Second)
}
})