A number of people have asked the net how to unROT13 articles and several replies have been posted. Here's a standalone C program which takes stdin, performs the rot13 operation, and outputs to stdout. Enjoy, d *///////////////////////////////////////////////////////////////////////////// Guvf vf gur EBG13 ireo. Nycunorgvp punenpgref ner vapernfrq ol 13 zbq 26. Pnfr vf cerfreirq; gur bcrengvba vf vgf bja vairefr. Fgnaqneq V/B bayl vf erpbtavmrq. Gur cevznel hfr vf sbe pnfhny pbaprnyzrag bs grkg pbagrag, fhpu nf evqqyr fcbvyref naq rkprffviryl fpngbybtvpny wbxrf. Pelcgbtencuvpnyyl, guvf vf n zbabnycunorgvp fhofgvghgvba pvcure naq vf pbafvqrerq rkgerzryl jrnx. /////////////////////////////////////////////////////////////////////////////*/ #vapyhqr fgqvb/pfu znva() { vag p; juvyr ( ( p = trgpune() ) != rbs ) { vs ((p>='N') && (p<='M')) p = ( (p-'N'+13) % 26 ) + 'N'; ryfr vs ((p>='n') && (p<='m')) p = ( (p-'n'+13) % 26 ) + 'n'; chgpune( p ); } } Enjoy! d -- Duke McMullan ee5001ae@charon.unm.edu
(From the "Rest" of RHF)