Please Disable Ad-Block To View This Website.

If you block ads, this site can not survive!

Ads are very minimal for registered users. If you don't have an account please register now!

DOWNLOAD
 Full Scripts
 Addons
 Snippets
 DLLs
 MTS Themes
 Tutorials
 Misc.
 File Queue
 Download mIRC
INTERACT
 Screenshots
 Challenge
 Top Downloads
 Submit Form
 Forums

SEARCH
Site Search

FRIENDS
Link to us!
PhotoShelf

Top Challenge Entrants

  # User Points
  1 jaytea 587
  2 [Znork] 303
  3 urza 297
  4 Ag2X 288
  5 dr_Eamer 255
  6 Albie 199
  7 Chessnut 197
  8 A Noniem 194
  9 zzattack 186
  10 Kol 185
  11 m910q 168
  12 Sephiroth 115
  13 patje 114
  14 Auron956 114
  15 chid 110
  16 Ohad2121 92
  17 SkorpSSS 87
  18 DixrouE 84
  19 Suchorski 83
  20 ^Vampire^ 74
Challenge:Obfuscated Code
Start:January 18th 2006
End:February 3rd 2006
Description:

new challenges as of 2006!

In this challenge you are asked to take the obfuscated code below and shorten it as much as possible.

The code has been deliberately made longer than necessary. You will need to understand what the code does in order to shorten it substantially. The code MUST return the same output as the code below.

Here is the code:


alias obs {
var %=, %$ 1,%%,%:,%:.,%l $len($1-) | while %$ <= %l { %= = $calc($asc($mid($1-,%$,1))/2.9+%=) | %$ = %$ + 1 } | %= = $left(%=,$pos(%=,.)) | %l = $iif(*0 iswm %l,9,$right(%l,1)) | %$ = 1 | while %$ <= $len(%=) { %: = $mid(%=,%$,%l)
while %: { %:. = $iif($calc(%: % ($asc(%)-21)) > 9,$chr($calc(5*11+$v1)),$v1) $+ %:. | %: = $int($calc(%: /($asc(/:.)-31))) } | %% = %% $+ $iif(%:.,$v1,0) | %$ = %$ + %l } | return %% }



Example:



$obs(z) = 4
$obs(123456) = 6A
$obs(?:@~0-+) = 9A
$obs('';,,.,//??///##=-2990425//:!::::!@#s]/) = 2AD





Hint: V2hpbGUgdGhlcmUgaXMgYSBtaXJjIHBhcnNlciBlcnJvciB5b3VyIGNvZGUgd2lsbCByZW1haW4gdmFsaWQu


Rules:

  • Alias name must remain 'obs'
  • No dlls, coms, sockets or regular expressions
  • One submission per user
  • Your code will be taken for EXACTLY as submitted. Nothing will be changed in your submitted code - even if a subtle mistake is found.
  • Alias will be run on mirc v6.16 $decode is allowed.
  • Script must give correct results after consecutive runs.
  • File will be loaded into the remotes section
  • Code will sometimes return nothing ($null) - This is intentional.
  • File we will be using to count the code: countcode.mrc
  • Alias will be run on a mirc with no variables set - a clean mirc.
  • Alias MUST return the same output as the alias above - your code will be tested against input values of different character sets and lengths of up to 900 chars against the original 'obs'.

    Entries will be judged on code size and whether they return the same output as the original 'obs' alias.