Towards AI Can Help your Team Adopt AI: Corporate Training, Consulting, and Talent Solutions.

Publication

DateTime Manipulations with Python
Latest   Machine Learning

DateTime Manipulations with Python

Last Updated on July 20, 2023 by Editorial Team

Author(s): Bindhu Balu

Originally published on Towards AI.

In Python, date, time, and DateTime classes provide a number of functions to deal with dates, times, and time intervals. Date and DateTime are an object in Python, so when you manipulate them, you are actually manipulating objects and not string or timestamps. Whenever you manipulate dates or times, you need to import DateTime function.

The DateTime classes in Python are categorized mainly into 5 classes.

date — Manipulate just date ( Month, day, year)time — Time independent of the day (Hour, minute, second, microsecond)DateTime — Combination of time and date (Month, day, year, hour, second, microsecond)time delta — A duration of… Read the full blog for free on Medium.

Join thousands of data leaders on the AI newsletter. Join over 80,000 subscribers and keep up to date with the latest developments in AI. From research to projects and ideas. If you are building an AI startup, an AI-related product, or a service, we invite you to consider becoming a sponsor.

Published via Towards AI

Feedback ↓