github.com/gnolang/gno@v0.0.0-20240520182011-228e9d0192ce/gnovm/tests/files/range6.gno (about) 1 package main 2 3 import "fmt" 4 5 func main() { 6 m := map[int]bool{1: true, 3: true, 5: true} 7 var n int 8 for range m { 9 n++ 10 } 11 fmt.Println(n) 12 } 13 14 // Output: 15 // 3