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.
Converts a hexadecimal color code to a tuple of integers corresponding to its RGB components.
Python, String · Sep 15, 2020
Finds the items that are parity outliers in a given list.
Python, List · Nov 2, 2020
Returns the sum of the powers of all the numbers from start
to end
(both inclusive).
Python, Math · Nov 2, 2020
Converts an integer to its roman numeral representation. Accepts value between 1
and 3999
(both inclusive).
Python, Math · Nov 2, 2020
Converts the values of RGB components to a hexadecimal color code.
Python, String · Nov 2, 2020
Calculates the average of a list, after mapping each element to a value using the provided function.
Python, Math · Nov 2, 2020
Initializes a list containing the numbers in the specified geometric progression range.
Python, Math · Nov 2, 2020
Returns the maximum value of a list, after mapping each element to a value using the provided function.
Python, Math · Nov 2, 2020
Returns the minimum value of a list, after mapping each element to a value using the provided function.
Python, Math · Nov 2, 2020
Calculates the sum of a list, after mapping each element to a value using the provided function.
Python, Math · Nov 2, 2020
Finds and returns the list of prime factors of a number.
Python, Math · May 24, 2023