Pastebin launched a little side project called VERYVIRAL.com, check it out ;-) Want more features on Pastebin? Sign Up, it's FREE!
Guest

python

By: a guest on Dec 24th, 2010  |  syntax: Python  |  size: 0.25 KB  |  views: 488  |  expires: Never
download  |  raw  |  embed  |  report abuse  |  print
Text below is selected. Please press Ctrl+C to copy to your clipboard. (⌘+C on Mac)
  1. import string
  2.  
  3. characters = string.maketrans('a ''b ''c', '1''2''3')
  4.  
  5. text = raw_input(' Write text: ').translate(characters)
  6.  
  7. print '====================================='
  8.  
  9. print '\nCONVERTION COMPLETE !'
  10. print '\nRESULT: {text}\n'.format(text=text)