### Question:
ScheduleImpl implements SealedSchedule<R, A, B>, Schedule.Update<R, S, A>, Schedule.Extract<A, S, B> { @Override public <C> Schedule<R, A, C> map(Function1<? super B, ? extends C> mapper) { return ScheduleImpl.of( initial(), this::update, (a, s) -> mapper.apply(extract(a, s))); } private  ScheduleImpl(); abstract URIO<R, S> initial(); @Override Schedule<R, A, C> map(Function1<? super B, ? extends C> mapper); @Override Schedule<R, C, B> contramap(Function1<? super C, ? extends A> comap); Schedule<R, A, B> andThen(Schedule<R, A, B> next); @SuppressWarnings("unchecked") Schedule<R, A, Either<B, C>> andThenEither(Schedule<R, A, C> next); @SuppressWarnings("unchecked") @Override Schedule<R, A, Tuple2<B, C>> zip(Schedule<R, A, C> other); @SuppressWarnings("unchecked") @Override Schedule<R, A, C> compose(Schedule<R, B, C> other); @Override Schedule<R, A, Z> foldM(Z zero, Function2<Z, B, ZIO<R, Unit, Z>> next); @Override Schedule<R, A, B> addDelayM(Function1<B, URIO<R, Duration>> map); @Override Schedule<R, A, B> untilInputM(Function1<A, UIO<Boolean>> condition); @Override Schedule<R, A, B> untilOutputM(Function1<B, UIO<Boolean>> condition); @Override Schedule<R, A, B> check(Function2<A, B, UIO<Boolean>> condition); static ScheduleImpl<R, S, A, B> of(
      URIO<R, S> initial, 
      Update<R, S, A> update,
      Extract<A, S, B> extract);  }### Answer:
@Test public void repeatDelay(@Mock Consumer1<String> console) { ZIO<Nothing, Throwable, Unit> print = ZIO.exec(() -> console.accept("hola")); Schedule<Nothing, Unit, Unit> recurs = Schedule.<Nothing, Unit>recurs(2).zipRight(Schedule.identity()); Schedule<Nothing, Unit, Integer> spaced = Schedule.spaced(Duration.ofMillis(500)); ZIO<Nothing, Throwable, Tuple2<Duration, Unit>> timed = print.repeat(recurs.zipLeft(spaced)).timed(); Either<Throwable, Tuple2<Duration, Unit>> provide = timed.provide(nothing()); assertTrue(provide.map(Tuple2::get1).getRight().toMillis() > 1000); verify(console, times(3)).accept("hola"); }