Last active
May 3, 2020 15:34
-
-
Save timtreis/11402360b9b5df0e98f4c8b411672e10 to your computer and use it in GitHub Desktop.
Python helper functions
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
print("Successfully imported ttreis helper functions") | |
def rgb2hex(r,g,b): | |
return "#{:02x}{:02x}{:02x}".format(r,g,b) | |
somsault_1 = rgb2hex( 0, 0, 0) # black | |
somsault_2 = rgb2hex( 0, 73, 73) # dark grey | |
somsault_3 = rgb2hex( 0, 146, 146) #009999, approx. "Persian Green" | |
somsault_4 = rgb2hex(255, 109, 182) | |
somsault_5 = rgb2hex(255, 182, 119) # brown |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment