static void printBenchResult(long repetitions) { printBenchResult(lastTiming(), repetitions); } static void printBenchResult(long time, long repetitions) { double secs = toSeconds(time)/repetitions; if (secs >= 1) ret with print("Each step took: " + formatDouble(secs, 3) + " s"); double ms = secs*1000; if (ms >= 1) ret with print("Each step took: " + formatDouble(ms, 3) + " ms"); double us = ms*1000; if (us >= 1) ret with print("Each step took: " + formatDouble(us, 3) + " µs"); double ns = us*1000; print("Each step took: " + iround(ns) + " ns"); }