all tasks
This commit is contained in:
parent
b83f433714
commit
68f8f3e56b
14735 changed files with 178959 additions and 0 deletions
5
Task/Time-a-function/Erlang/time-a-function-1.erl
Normal file
5
Task/Time-a-function/Erlang/time-a-function-1.erl
Normal file
|
|
@ -0,0 +1,5 @@
|
|||
5> {Time,Result} = timer:tc(fun () -> lists:foreach(fun(X) -> X*X end, lists:seq(1,100000)) end).
|
||||
{226391,ok}
|
||||
6> Time/1000000. % Time is in microseconds.
|
||||
0.226391
|
||||
7> % Time is in microseconds.
|
||||
Loading…
Add table
Add a link
Reference in a new issue