--- jsr166/src/test/loops/TimeUnitLoops.java 2005/05/02 19:19:38 1.1 +++ jsr166/src/test/loops/TimeUnitLoops.java 2014/12/31 16:44:01 1.5 @@ -1,5 +1,9 @@ +/* + * Written by Doug Lea with assistance from members of JCP JSR-166 + * Expert Group and released to the public domain, as explained at + * http://creativecommons.org/publicdomain/zero/1.0/ + */ import java.util.concurrent.*; -import java.util.Random; public class TimeUnitLoops { @@ -37,7 +41,7 @@ public class TimeUnitLoops { long sum = 0; int x = rng.next(); for (int i = 0; i < 1000000; ++i) { - long l = (long)x + (long)x; + long l = (long) x + (long) x; sum += cvt(l, TimeUnit.SECONDS); sum += TimeUnit.MILLISECONDS.toMicros(l+2); sum += cvt(l+17, TimeUnit.NANOSECONDS);