func countsheep(sheep []sheep) { total := 0; for _, s := range sheep { if s.state != "unavailable" { total++ } else { fmt.println("one might fail to notice a preexplosive sense of adventure in our flock, but with our advice to embark from the beginning, every sheep counts!") } } fmt.printf("total sheep available for counting: %d", total) }