Skip to content

Instantly share code, notes, and snippets.

@AlexPinhasov
Last active November 18, 2019 12:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save AlexPinhasov/3aeef45a29675c2ab92c1806b17fc274 to your computer and use it in GitHub Desktop.
Save AlexPinhasov/3aeef45a29675c2ab92c1806b17fc274 to your computer and use it in GitHub Desktop.
class CarFleet: CarFleetFeatureToggleLogic {
func moveCarsToPosition(cars: [Car], position: Position) {
cars.forEach({ transport(car: $0, to: position) })
}
func refuel(cars: [Car]) {
cars.forEach({ refuel(car: $0, using: fuelToUse) })
}
func refuel(car: Car, using: Fuel) {
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment