The Python snippet collection contains helper functions for Python 3.6. It includes utilities for most common data types, such as primitivies, lists, dictionaries and date objects.
Combines two lists into a dictionary, using the first one as the keys and the second one as the values.
Python, List · Nov 2, 2020
It's generally not a good idea to use bare except
clause in Python, but do you know why?
Python, Error · Feb 20, 2022
Python provides two distinct comparison operators for different task. Stop mixing them up using this quick guide.
Python, Type · Jun 12, 2021
Learn everything you need to know about Python's slice assignment with this handy guide.
Python, List · Jun 12, 2021
Executes the provided function once for each list element.
Python, List · Sep 15, 2020
Calculates the greatest common divisor of a list of numbers.
Python, Math · Sep 15, 2020
Returns a list of indexes of all the occurrences of an element in a list.
Python, List · Oct 11, 2020
Checks if a string is an anagram of another string (case-insensitive, ignores spaces, punctuation and special characters).
Python, String · Nov 2, 2020
Creates a flat list of all the keys in a flat dictionary.
Python, Dictionary · Nov 2, 2020
Returns the least common multiple of a list of numbers.
Python, Math · Nov 2, 2020