import timeit print(timeit.timeit('list(map(lambda x: x*x, range(10)))'))print(timeit.timeit('[x*x for x in range(10)]'))
Standard input is empty
1.5655903220176697 0.7803761437535286
The brand new service which powers Ideone!
Widget for compiling and running the source code in a web browser!