func (b Bus) DepartsIn(after time.Duration) time.Duration {
	frequency := b.ID
	afterMinutes := int((after).Minutes())

	nextDepartureMinutes := frequency - (afterMinutes % frequency)

	return time.Minute * time.Duration(nextDepartureMinutes)
}
// DepartsIn returns the time until this bus's next departure after the given time,
// relative to time 0.
DepartsIn returns the time until this bus's next departure after the given time,
relative to time 0.
// DepartsIn returns the time until this bus ' s next departure after the given time // relative to time 0 .
func (b Bus) DepartsIn(after time.Duration) time.Duration {
	frequency := b.ID
	afterMinutes := int((after).Minutes())
	nextDepartureMinutes := frequency - (afterMinutes % frequency)
	return time.Minute * time.Duration(nextDepartureMinutes)
}
func ( b Bus ) DepartsIn ( after time . Duration ) time . Duration { frequency := b . ID afterMinutes := int ( ( after ) . Minutes ( ) ) nextDepartureMinutes := frequency - ( afterMinutes % frequency ) return time . Minute * time . Duration ( nextDepartureMinutes ) }
DepartsIn returns the time until this bus's next departure after the given time,
relative to time 0.
DepartsIn returns the time until this bus ' s next departure after the given time relative to time 0 .