W3Schools Tryit Editor
[
フレーム
]
Run ❯
Get your
own Python
server
Go to Spaces
Ctrl+Alt+P
import cProfile, pstats def work(): s = 0 for i in range(20000): s += i*i return s pr = cProfile.Profile() pr.enable() work() pr.disable() pstats.Stats(pr).strip_dirs().sort_stats("time").print_stats(5)
2 function calls in 0.001 seconds
Ordered by: internal time
ncalls tottime percall cumtime percall filename:lineno(function)
1 0.001 0.001 0.001 0.001 prog.py:3(work)
1 0.000 0.000 0.000 0.000 {method 'disable' of '_lsprof.Profiler' objects}
AltStyle
によって変換されたページ
(->オリジナル)
/
アドレス:
モード:
デフォルト
音声ブラウザ
ルビ付き
配色反転
文字拡大
モバイル