diff options
author | Flu0r1ne <flur01ne@flu0r1ne.net> | 2021-09-03 21:45:03 -0500 |
---|---|---|
committer | Flu0r1ne <flur01ne@flu0r1ne.net> | 2021-09-04 13:24:09 -0500 |
commit | 8c803d453201c8b85172d984fc1aee9eb5af2173 (patch) | |
tree | 01502d65f8c959dd92add6982aaaa0fb5f01284a | |
parent | 2d197f1ce3eac8cecb5a655fcb5343cbe562ab1a (diff) | |
download | planr-8c803d453201c8b85172d984fc1aee9eb5af2173.tar.xz planr-8c803d453201c8b85172d984fc1aee9eb5af2173.zip |
Forgo scoring zero point assignment
-rw-r--r-- | cmd/planr/sub/cli.go | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/cmd/planr/sub/cli.go b/cmd/planr/sub/cli.go index 0e6a942..d667b88 100644 --- a/cmd/planr/sub/cli.go +++ b/cmd/planr/sub/cli.go @@ -116,7 +116,9 @@ func printResults(passed, tc_total int, earned, points_total float64) { percent := earned / points_total * 100 - pprintLabeled("score", fmt.Sprintf( - "%.2f/%.2f ~= %.1f%%", earned, points_total, percent, - )); + if points_total != 0 { + pprintLabeled("score", fmt.Sprintf( + "%.2f/%.2f ~= %.1f%%", earned, points_total, percent, + )); + } } |