in reply to My First JAPH
Below is an example of how you could have worked this to make it more obfuscated.
I hope this helps you.# You may want to change the name of $a $a = "a"; # Don't use a simple number, make a math statement instead # Remember that $a++ will increment after the expression is # evaluated. I used %_ as the hash to add some confusion for (1 .. (6/3*10+15/2.5)){$_{$_} = $a++;} # You may want to write a piece of code that generates # this string to hide things a bit more $c = '01010.10101.10011.10100..00001.01110.01111 .10100.01000.00101.10010..10000.00101.10010.01100. .01000.00001.00011.01011.00101.10010'; # Using @_ to add some more confusion @_= split( /\.\n*/, $c ); # Reuse $a and put your sub in it. Note the use of >> # instead of multiple if statements $a = sub {$c = 0; for (0..$#_){$c+=(16>>$_) if $_[$_];}$c;}; foreach ( 0 .. $#_ ) { # Replace your if statement with trinary, dereferance $a to call your +sub $japh.=($_[$_] ne "")?$_{&$a(split(/\s*/,$_[$_]))}:" "; } $japh =~ s/\b([a-z])/\U\1/g; print $japh,"\n"; # Here is it squished together. $a="a";for(1..(6/3*10+15/2.5)){$_{$_}=$a++;} $c='01010.10101.10011.10100..00001.01110.01111 .10100.01000.00101.10010..10000.00101.10010.01100. .01000.00001.00011.01011.00101.10010'; @_=split(/\.\n*/,$c);$a=sub{$c = 0; for(0..$#_){$c+=(16>>$_)if$_[$_];}$c;}; foreach(0..$#_){$japh.=($_[$_]ne"")? $_{&$a(split(/\s*/,$_[$_]))}:" ";} $japh =~ s/\b([a-z])/\U\1/g; print $japh,"\n";
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: My First JAPH
by dsb (Chaplain) on Jan 25, 2001 at 19:19 UTC |