Understanding Underscores in Python

Ever wonder why sometimes attributes, methods in Python start with single underscore, double underscore(“dunder”), end with single underscore etc. Single and double underscores have a meaning in...

High Order functions

A high order function is a function that operates on other functions, either by taking a function as it argument or by returning a function. map(function, iterable) Returns an iterator that applies function to...

Dealing with multiple iterables in Python using zip()

Python’s zip() function creates an iterator that will aggregate elements from two or more iterables. zip() maps the similar index of multiple containers so that they can be used just using as single entity...

Category - Programming

Programming is the process of taking an algorithm and encoding it into a notation, a programming language, so that it can be executed by a computer. Although many programming languages and many different types of computers exist, the important first step is the need to have the solution.

python1-1

String in Python

Textual data in Python is handled with str objects. Since default handling of Text in Python2 and Python3 is different, it is importantto understand the difference. In Python 2 , by default, ‘str’ object is...

python1-1

Tuple in Python

Tuple is a data structure in Python which is an immutable , ordered collection of objects. Tuples are faster and consume less memory. Create an empty tuple t = () or t = tuple() Create a tuple with single element t =...

python1-1

Sets in Python

A Set in Python is a data structure that contains an un-ordered collection of distinct objects. A set in python is similar to sets in mathematics. Use Case : removing duplicates from a sequence, performing mathematical...

Python

Dictionary in Python

A dictionary is an un-ordered data structure, its elements are stored as a key:value pair.Key must be unique and immutableIf key is not unique, last value of key will override previous values # Create an empty...

Python

An Overview Of Python

A high level scripting language, Python codes are designed to be highly readable. Its programs are written in nearly regular English and are neatly indented. It uses English keywords, concise codes, and simple syntax.