/* * An example of using a labelled break to exit out of two loops * @author gtowell * created: July 30, 2021 */ package main import "fmt" func main() { b(50,20) b(500,4) } // function to just do two loops where the max of each loop is // passed into the function func b(outr int, innr int) { a := 0 Loop1: for oo:=0; oo100) { break Loop1; } } fmt.Printf("outr %d\n", oo) } }