### Question:
Functions { public static DoubleFunction<AtomicLong> age(final Clock clock) { return new DoubleFunction<AtomicLong>() { @Override public double apply(double t) { return (clock.wallTime() - t) / 1000.0; } }; } private  Functions(); static DoubleFunction<AtomicLong> age(final Clock clock); static ToDoubleFunction<T> invokeMethod(final Method method); static Predicate<Meter> nameEquals(String name); static final DoubleFunction<? extends Number> IDENTITY; static final DoubleFunction<AtomicLong> AGE; }### Answer:
@Test public void ageFunction() { clock.setWallTime(5000L); final DoubleFunction<AtomicLong> f = Functions.age(clock); Assertions.assertEquals(f.apply(1000L), 4.0, 1e-12); }