Built-in Methods

Python str() Function

Python str() function is one of the built-in functions. This function returns the string representation of the object. If there is no argument provided, it returns an empty string. Python str() Function Examples Let’s look at some simple examples of the str() function. How to implement str() function for an Object When we call the

Python str() Function Read More »

Assertions in Python

Let us learn about a commonly used testing and debugging technique called Assertions in Python. We will learn what assertions are, why they are used, when not to use them, and their syntax. So let’s get started. What are Assertions in Python? Assertions in Python are statements that are used to assert a condition on

Assertions in Python Read More »

The Dot Notation in Python

Let’s discuss the dot notation in Python today. If you have even a little experience with coding in Python, or if you’ve been following our AskPython blog, you should have come across the term Object-Oriented Programming. It is a programming paradigm based on the concept of real-world Objects. Each object has certain attributes that describe

The Dot Notation in Python Read More »