• M4mb0@fediverser.communick.devB
    link
    fedilink
    English
    arrow-up
    1
    ·
    1 year ago

    Try this one:

    results["now()"] = timeit.timeit(
        setup="import datetime; now=datetime.datetime.now", stmt="now()", number=number
    )
    
    • wil19558@fediverser.communick.devOPB
      link
      fedilink
      English
      arrow-up
      1
      ·
      1 year ago

      Interesting! I’m compiling user suggestions: I’ll do a round 2 with comparison between Python versions, Ubuntu, WSL and Windows.

      Thanks for the feedback!