inflect($word); } $duration = \microtime(\TRUE) - $start; echo \count($words) . " words, \t"; echo \number_format($duration, 3) . " seconds, \t"; echo \number_format(\memory_get_peak_usage(\TRUE) / 1000000.0, 3) . " MB\n"; $sumTimes += $duration; $count++; } echo "---------------\n"; $avg = $sumTimes / $count; echo 'Avg duration: ' . \number_format($avg, 3) . " seconds\n";