
Data Structure
Networking
RDBMS
Operating System
Java
MS Excel
iOS
HTML
CSS
Android
Python
C Programming
C++
C#
MongoDB
MySQL
Javascript
PHP
- Selected Reading
- UPSC IAS Exams Notes
- Developer's Best Practices
- Questions and Answers
- Effective Resume Writing
- HR Interview Questions
- Computer Glossary
- Who is Who
SaiKrishna Tavva has Published 98 Articles

SaiKrishna Tavva
64K+ Views
The ISO 8601 standard defines an internationally recognised format for representing dates and times. ISO 8601 is a date and time format that helps remove different forms of the day, date, and time conventions worldwide. In this article, we will discuss several methods to get an ISO 8601 date in ... Read More

SaiKrishna Tavva
505 Views
Python provides different ways to find the execution time taken by a script or specific parts of the code such as using the functions from the time module, like time.time() or time.clock(). The following are some common methods used to measure execution time in Python: Using ... Read More

SaiKrishna Tavva
5K+ Views
Python provides various modules, such as time, datetime, and timeit, to measure time with high accuracy. These modules offer high-resolution clocks to measure time intervals. The following are several methods used to measure time with high precision in Python. Using time.time() Method ... Read More

SaiKrishna Tavva
2K+ Views
We can use the PyMongo library (the official Mongodb driver for Python) to connect to a Mongodb database and use it to insert, update, delete, etc objects. To include date and time information, Mongodb supports ISODate format, and PyMongo provides direct support for Python's datetime.datetime objects. There are multiple ways ... Read More

SaiKrishna Tavva
36K+ Views
We can use the datetime module to convert a datetime to a UTC timestamp in Python. If we already have the datetime object in UTC, then the timestamp() function can be directly used to get a UTC timestamp. This function returns the time since epoch for that datetime object. If we ... Read More

SaiKrishna Tavva
981 Views
In Python, the mktime() function (from the time module) assumes that the passed tuple is in local time, while the calendar.timegm() (from the calendar module) assumes it's in GMT/UTC. Depending on the interpretation, the tuple represents a different time, so both functions return different values (seconds since the epoch are UTC-based). The difference between the ... Read More

SaiKrishna Tavva
391 Views
Nested character class subtraction in Python's regular expressions allows us to define complex character sets by removing characters from an existing character class, including another character class by using the '-' operator. It works from the innermost to outermost character class, and subtractions are evaluated from left to right ... Read More

SaiKrishna Tavva
1K+ Views
While working with Python regex, if we want to match everything except certain characters, then we can use negated character classes by placing a caret (^) as the first character inside square brackets. The pattern [^abdfgh] will match any character not in that set. What is a Negated Character Class? ... Read More

SaiKrishna Tavva
552 Views
Two commonly used functions from the Python time module are time.time() and time.clock(). Each function provides a different purpose and returns different values depending on the platform (Windows vs. Unix). In Python 3.8, time.clock() was removed, so time.perf_counter() or time.process_time() are generally preferred over the older time.clock() for specific CPU time measurements. ... Read More

SaiKrishna Tavva
23K+ Views
In many real-world applications, timestamps are used to represent dates and times, but they are not human-readable. To make them understandable or use them in various datetime manipulations, it’s essential to convert them into Python’s datetime object. Python’s datetime module provides multiple functions to convert timestamps to datetime objects. Below ... Read More