timeitライブラリー 実行処理を計測するtimeitライブラリー timeit モジュールは、Pythonコードの実行時間を計測するためのツールです print(timeit.timeit("len(range(1000))"))