Pankaj Kumar

Pankaj Kumar

I have been working on Python programming for more than 12 years. At AskPython, I share my learning on Python with other fellow developers.
Python str.upper() Method: Syntax and Examples

Python str.upper() Method: Syntax and Examples

Converting a Python string to uppercase gives it an uppercase form. Python’s str.upper() method returns a copy of a string with its cased characters converted to uppercase. I’ll show how to call str.upper() and what happens to the original string…

Weather API Python: Analyze Historical Trends

Weather API Python: Analyze Historical Trends

Historical weather records can help answer how conditions varied during a chosen period. A weather API returns data for a requested location and time span, which Python can use to calculate summaries. This article shows how to send a historical…

OS mkdir: Create Directories in Python

OS mkdir: Create Directories in Python

A program may need a directory at a particular filesystem path. Python’s directory-creation calls let you create one directory or create missing parent folders along the path. This article explains the os mkdir operation and shows how os.mkdir() and os.makedirs()…

Python Array Example: 13 Operations

Python Array Example: 13 Operations

Working with a sequence of values in Python starts with choosing how to represent those values. The array module lets you create an array by choosing a type code and supplying starting values. This article demonstrates array operations and compares…

Building Bingo with Python

Want to build your own bingo game? Python is a good way to get started. You can put together a basic version without getting bogged down in complicated code, then add features once the thing actually works. There’s a bit…