Introduction to Functions in Python – A beginners giude

A function is a block of code that performs an operation usually a specific task.
Functions help break our program into smaller and modular chunks, making them resusable and redable. They prevent repetition of code.
You can pass data known as parameters… Read more

Similar

How to Write a Custom Comparator in Python

Generally, you want to use the built-in sorted() function which takes a custom comparator as its parameter. We need to pay attention to the fact that in Python 3 the parameter name and semantics have changed. How the custom comparator works When providing... (more…)

Read more »

Exploring Line Lengths in Python Packages

This week, Twitter upped their single-tweet character limit from 140 to 280, purportedly based on this interesting analysis of tweet lengths published on Twitter's engineering blog. The gist of the analysis is this: English language tweets display a rough... (more…)

Read more »