Skip to content

Instantly share code, notes, and snippets.

@yasyf
Created August 22, 2013 20:13
Show Gist options
  • Save yasyf/6312189 to your computer and use it in GitHub Desktop.
Save yasyf/6312189 to your computer and use it in GitHub Desktop.
#!/usr/bin/env python
notes_dict = {"c": "119","c#": "110", "db": "110", "d": "105", "d#": "100", "eb": "100", "e": "94", "f": "89", "f#": "84", "gb": "84", "g": "79", "g#": "74", "ab": "74", "a": "70", "a#": "66", "bb": "66", "b": "62", "c2": "59"}
notes_string = raw_input("Enter Notes (Delimited By Spaces): ")
notes = notes_string.split(" ")
print "to song"
for note in notes:
if note in notes_dict:
print " note %s 5" % (notes_dict.get(note))
print "end"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment