github.com/goplus/gop@v1.2.6/printer/_testdata/12-Select-comprehension/select.gop (about) 1 a := [2, 3, 5, 7, 9, 13, 17, 19, 23, 29, 31, 37, 41, 43, 47, 53, 59] 2 where := {i for i, v <- a if v == 19} 3 println("19 is at index", where) 4 5 if at, ok := {i for i, v <- a if v == 37}; ok { 6 println("37 is found! index =", at) 7 } 8 9 println("first element of a is:", {v for v <- a})