diff --git a/Section4/iota/main.go b/Section4/iota/main.go new file mode 100644 index 0000000..eab9134 --- /dev/null +++ b/Section4/iota/main.go @@ -0,0 +1,27 @@ +package main + +import "fmt" + +func main() { + const ( + c1 = iota + c2 = iota + c3 = iota + ) + fmt.Println(c1, c2, c3) + + const ( + a = (iota * 2) + 1 + b + c + ) + fmt.Println(a, b, c) + + const ( + x = -(iota + 2) + _ + y + z + ) + fmt.Println(x, y, z) +}