Ever wanted to hang out with all your budz on #warez, but haven't yet mastered their way of typing? Don't fret! This snippet of obfuscated code will convert anything from STDIN to l33t speak!
For example:
"Hey! What's up, you guys? This IRC channel rocks!"
becomes:
"HEy!11!1!!!!!1!!!! whaTZZZZZ Up Jo0 GUyzzZ?!!?!!?!?? ThIZzZz IRC ChAnNEL rOxORzZzZZz!!!111!1"
--
I write the code while the master is away!
For example:
"Hey! What's up, you guys? This IRC channel rocks!"
becomes:
"HEy!11!1!!!!!1!!!! whaTZZZZZ Up Jo0 GUyzzZ?!!?!!?!?? ThIZzZz IRC ChAnNEL rOxORzZzZZz!!!111!1"
while(<STDIN>){$_=lc($_);s/ou/oo/g;s/yo/jo/g;s/ck(s|\W)/xor$1/g;s/elit +e/leet/g;s/[\,\']//g;while(/[\?][\?\.\!]*/){my $ex=xp("Q","E");s/[\?] +[\?\.\!]*/$ex/;}while(/[\.\!]+/){my $ex=xp("E","1");s/[\.\!]+/$ex/;}s +/Q/\?/g;s/E/\!/g;while(/s([\W])/){my $ex="z" x int(rand(6)+1);s/s([\W +])/$ex$1/;}my $o;while (s/^(.)//s){my $c=$1;if(rand(1)>.5){$c=uc($c); +}else{$c=lc($c);}if(rand(1)>.5){$c=~tr/iseto/15370/;}$o.=$c;}print $o +;}sub xp{my ($a,$b)=@_;my $o=$a;my $len=int(rand(10)+5);for(my $x=0;$ +x<$len;$x++) {if(rand(1)>.4){$o.=$a;}else{$o.=$b;}}return $o;}
--
I write the code while the master is away!
|
---|
Replies are listed 'Best First'. | |
---|---|
Re: Useful obfuscation for chatting
by Masem (Monsignor) on Jun 20, 2001 at 01:58 UTC | |
by myocom (Deacon) on Jun 20, 2001 at 02:33 UTC | |
Re: Useful obfuscation for chatting
by Beatnik (Parson) on Jun 20, 2001 at 17:58 UTC |
Back to
Obfuscated Code