About 1,080,000 results
Open links in new tab
  1. How do I get the current time in Python? - Stack Overflow

    558 How do I get the current time in Python? The time module The time module provides functions that tell us the time in "seconds since the epoch" as well as other utilities.

  2. How do I measure elapsed time in Python? - Stack Overflow

    This gives the execution time in seconds. Another option since Python 3.3 might be to use perf_counter or process_time, depending on your requirements. Before 3.3 it was recommended to use time.clock …

  3. Python's time.clock() vs. time.time() accuracy? - Stack Overflow

    time.clock () On Unix, return the current processor time as a floating point number expressed in seconds. The precision, and in fact the very definition of the meaning of “processor time”, depends …

  4. How do I get the current time in milliseconds in Python?

    Jun 17, 2019 · In versions of Python after 3.7, the best answer is to use time.perf_counter_ns(). As stated in the docs: time.perf_counter() -> float Return the value (in fractional seconds) of a …

  5. time.time () or time.perf_counter () — which is faster?

    Feb 3, 2021 · The choice between time.time() and time.perf_counter() depends on the context in which you will use the function. That's because each function deals with a different "type of time". …

  6. How do I get time of a Python program's execution?

    Oct 13, 2009 · To measure a Python program's execution time, use the time module. Record the start time with time .time () before the code and the end time after. Subtract start from end to get the …

  7. windows - How do I measure time in C? - Stack Overflow

    The standard C library provides the time function and it is useful if you only need to compare seconds. If you need millisecond precision, though, the most portable way is to call timespec_get. It can tell time …

  8. What difference between the DATE, TIME, DATETIME, and TIMESTAMP …

    Jan 1, 1970 · The value stored will be the current date and time using the current session time zone in effect. But once a DATETIME column has been set, it will display the same regardless of what the …

  9. python - Can't install time module - Stack Overflow

    Mar 1, 2017 · Did you happen to name a file time.py (or a folder containing Python modules time)? If it's in your working directory, it will shadow the built-in time module.

  10. python - delay a task until certain time - Stack Overflow

    Jul 5, 2011 · 0 Here is a solution. This is independent of date because the new date-time "end2" has same date as current date-time and at the same time the date-time format is not changed.