// ValidCarIDs returns a set of all of the valid cars in the Championship - that is, the smallest possible list
// of Cars driven by the Entrants.
ValidCarIDs returns a set of all of the valid cars in the Championship - that is, the smallest possible list
of Cars driven by the Entrants.
// ValidCarIDs returns a set of all of the valid cars in the Championship - that is the smallest possible list // of Cars driven by the Entrants .
func (c *Championship) ValidCarIDs() []string {
	cars := make(map[string]bool)
	for _, class := range c.Classes {
		for _, e := range class.Entrants {
			cars[e.Model] = true
		}
	}
	var out []string
	for car := range cars {
		out = append(out, car)
	}
	return out
}
func ( c * Championship ) ValidCarIDs ( ) [ ] string { cars := make ( map [ string ] bool ) for _ , class := range c . Classes { for _ , e := range class . Entrants { cars [ e . Model ] = true } } var out [ ] string for car := range cars { out = append ( out , car ) } return out }
ValidCarIDs returns a set of all of the valid cars in the Championship - that is, the smallest possible list
of Cars driven by the Entrants.
ValidCarIDs returns a set of all of the valid cars in the Championship - that is the smallest possible list of Cars driven by the Entrants .