Thời gian dấu hàm [] trả về thời gian được biểu thị bằng số giây đã trôi qua kể từ ngày 1 tháng 1 năm 1970. Reputation by not being call is a overlay. Đầu tiên, chúng tôi sẽ nhận được thời gian hiện tại hoặc vấn đề rõ ràng về ngày và thời gian cần thiết mà chúng tôi muốn có dấu thời gian. There some way to have been day and time. Chúng ta sẽ thấy họ khi chúng ta trải nghiệm qua các ví dụ. Sau đó, chúng tôi sẽ chuyển DateTime thành Timestamp bằng hàm Timestamp []. datetime thành dấu thời gian bằng hàm timestamp[]
Cuối cùng, chúng tôi sẽ làm tròn dấu thời gian bằng vài giây và mili giây và đánh máy rõ ràng vào loại dữ liệu nguyên số và công việc của chúng tôi đã hoàn thành
Ví dụ 1. Time in integer of the date and now at
Tại đây, tôi nhập mô-đun -DateTime để sử dụng chức năng DateTime từ nó. And after that use dateTime function. now [] to have been date and the current time. Chuyển đổi đối tượng DateTime thành dấu thời gian bằng phương thức DateTime. Dấu thời gian []. Chúng tôi sẽ nhận được dấu thời gian trong vài giây. Và sau đó làm tròn dấu thời gian và đánh máy rõ ràng số điểm nổi vào một số nguyên để được đánh dấu thời số nguyên trong vài giây
Python3
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000003
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000004
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000003
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000006
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000000_______01
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000003
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000004
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000005
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000009
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000060
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000001
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000063
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000064
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000065
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000066
đầu ra
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000006
Ví dụ 2.  
Cung cấp ngày và thời gian dưới dạng tham số bên trong hàm DateTime[]. Chuyển đổi đối tượng DateTime thành dấu thời gian bằng phương thức DateTime. Dấu thời gian []. Chúng tôi sẽ nhận được dấu thời gian trong vài giây. Làm tròn dấu thời gian và đánh dấu rõ ràng số điểm nổi vào một số nguyên để có được dấu thời gian nguyên trong vài giây. Chúng ta cũng có thể chuyển đổi nó thành mili giây bằng cách nhân nó BY1000 để có dấu hiệu thời lượng nguyên tính bằng mili giây
Python3
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000003
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000004
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000003
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000006
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000000_______01
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000024
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000025
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000005
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000009
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000060
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000001
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000031
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000064
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000065
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000002
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000009
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000037
Ví dụ 2.  
Cung cấp ngày và thời gian dưới dạng tham số bên trong hàm DateTime[]. Chuyển đổi đối tượng DateTime thành dấu thời gian bằng phương thức DateTime. Dấu thời gian []. Chúng tôi sẽ nhận được dấu thời gian trong vài giây. Làm tròn dấu thời gian và đánh dấu rõ ràng số điểm nổi vào một số nguyên để có được dấu thời gian nguyên trong vài giây. Chúng ta cũng có thể chuyển đổi nó thành mili giây bằng cách nhân nó BY1000 để có dấu hiệu thời lượng nguyên tính bằng mili giây
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000065
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000032
đầu ra
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 1514817000000
Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843451= Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843453Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843454Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843455Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843456Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843455Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843456Múi giờ. Châu Á/Kolkata Datetime. 2021-08-25 15. 09. 05. 194413+05. 30 Dấu thời gian số nguyên. 16298843455từ0từ1
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000026
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000028
Python3
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000038
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000007__12
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 15148170000001____02
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000049
Datetime: 2018-01-01 20:00:00 Integer timestamp in seconds: 1514817000 Integer timestamp in milliseconds: 151481700000064
Ví dụ 3. UTC [Thời gian phổ biến] Time time integer]
Đầu tiên, chúng ta nhập thời gian UTIC bên trong đối tượng DateTime. Ngày giờ []. Sau đó, chúng tôi chuyển các đối tượng cho hàm d. timtuple[] cung cấp một bộ chứa các tham số như năm, tháng, ngày, v. v. , sau đó sử dụng lịch hàm, chúng tôi chuyển đổi DateTime thành dấu thời gian UTC nguyên UTC