From c190e196a1a885b665397e94d0f092077257d51a Mon Sep 17 00:00:00 2001 From: Samuel Berthe Date: Tue, 4 Oct 2022 20:43:25 +0200 Subject: [PATCH] fix tests --- slice_example_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/slice_example_test.go b/slice_example_test.go index 6ba2b1c3..a0c6a426 100644 --- a/slice_example_test.go +++ b/slice_example_test.go @@ -125,9 +125,9 @@ func ExampleGroupBy() { return i % 3 }) - for _, item := range result { - fmt.Printf("%v\n", item) - } + fmt.Printf("%v\n", result[0]) + fmt.Printf("%v\n", result[1]) + fmt.Printf("%v\n", result[2]) // Output: // [0 3] // [1 4]