2012年1月23日 星期一

Execution time in Ruby


def time
start = Time.now
yield
Time.now - start
end

time do
# put code here ...
end

沒有留言:

張貼留言