TIP: Click on subject to list as thread! ANSI
echo: os2prog
to: Sean Dennis
from: Tom Torfs
date: 1999-09-19 22:29:00
subject: ... Perl

Sean Dennis wrote in a message to David Van Hoose:

 SD> ROT13 is a simple 'encryption' code (think of the 'Simple Caesar')
 SD> that people use in USENET to prevent joke punchlines and tv show
 SD> plot spoilers from being read until you're ready.  GoldEd also
 SD> supports this, but it's not encouraged to use this in FidoNet.
 SD> It's extremely easy to write a program that does the same thing. 

Anyhow, just in case:

/* Rot13 filter */

#include 
int main(void)
{
   int c,i;

   while ((c=fgetc(stdin))!=EOF)
   {
      if (c>='a' && c<='z')
         c = (((c-'a')+13)%26)+'a';
      else if (c>='A' && c<='Z')
         c = (((c-'A')+13)%26)+'A';
      fputc(c,stdout);
   }

   return 0;
}

greetings,
Tom
tomtorfs@village.uunet.be

--- timEd/2 1.10.y2k+
724/10
* Origin: 80X86 BBS 32-15-24.62.32 V.34/V.FC (24h/24h) (2:292/516)

SOURCE: echoes via The OS/2 BBS

Email questions or comments to sysop@ipingthereforeiam.com
All parts of this website painstakingly hand-crafted in the U.S.A.!
IPTIA BBS/MUD/Terminal/Game Server List, © 2025 IPTIA Consulting™.