LoginSignup
2
3

More than 3 years have passed since last update.

Pythonで処理時間計測

Posted at

この記事を参考にさせていただきました。

ループを回す系の処理で、速度が遅い場合の時間計測をどうするんだったけかなとすぐ忘れてしまうので。

import time
start = time.time()
print("1: {}".format(time.time() - start))
# smt
print("2: {}".format(time.time() - start))
2
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
2
3