Skip to content

Instantly share code, notes, and snippets.

@Suhaib3100
Created December 4, 2024 09:15
Show Gist options
  • Save Suhaib3100/47dd42e850797047913bac4d4b617208 to your computer and use it in GitHub Desktop.
Save Suhaib3100/47dd42e850797047913bac4d4b617208 to your computer and use it in GitHub Desktop.
Timestamps 2 converting into teadable
from datetime import datetime
# Example timestamp
example_timestamp = 1701739200 # Example: Dec 4, 2024
# Convert timestamp to datetime
converted_datetime = datetime.fromtimestamp(example_timestamp)
print("Readable Date and Time:", converted_datetime)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment