Skip to content

Instantly share code, notes, and snippets.

@betrcode
Created March 12, 2014 09:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save betrcode/9503396 to your computer and use it in GitHub Desktop.
Save betrcode/9503396 to your computer and use it in GitHub Desktop.
Convert a dict with integer keys to a stringified list of stringified keys in Python
channels = {1: 'SVT1', 2: 'SVT2', 3: 'TV3', 4: 'Kanal 4'}
str(map(str, channels.keys()))
@betrcode
Copy link
Author

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment