paulk_asert
04/20/2026, 8:48 PMlong timeMillis(Closure c) {
long start = System.currentTimeMillis()
c.call()
System.currentTimeMillis() - start
}
Long duration = timeMillis {
println 'Hi'
sleep 500
println 'Bye'
}
println duration
// Hi
// Bye
// 507