Skip to content

Instantly share code, notes, and snippets.

@rpearl
Created December 24, 2016 19:33
Show Gist options
  • Save rpearl/352e4bf12dedb24aa389800375e5a4ff to your computer and use it in GitHub Desktop.
Save rpearl/352e4bf12dedb24aa389800375e5a4ff to your computer and use it in GitHub Desktop.
import sys
voicemap = str.maketrans({
'g': u'k\u3099',
'G': u'K\u3099',
'z': u's\u3099',
'Z': u'S\u3099',
'd': u't\u3099',
'D': u'T\u3099',
'b': u'h\u3099',
'B': u'H\u3099',
'p': u'h\u309A',
'P': u'H\u309A',
})
def main():
s = sys.stdin.read()
print(s.translate(voicemap))
if __name__ == '__main__':
main()
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment