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:Smallest $duration()
Started: May 29th, 2001
Ends: June 3rd, 2001

In this challenge, you are asked to re-create the $duration identifier, the winner will be determined on the smallest file size. It must work exactly like $duration, except you don't have to support going backwards (eg, $duration(1min 32secs)).

More rules:
  • You can not use mIRC's $duration identifier.
  • The name of your alias must be 'dur'.
  • One submission per person.
  • Must be submitted as one script file named <yourname>_duration.mrc. (e.g. fubar_duration.mrc)
  • Must be an alias file.

    Entries were judged on the smallest code size. Valid entries had extra carriage returns and linefeeds, that are added by mIRC, removed.

    Challenge Entries:

    There were 32 entries submitted, 13 valid and 19 invalid. Disqualified entries are not shown.

    Winner!

    warrior (184 bytes)

    dur %t = $1 | return $iif(!%t,0secs,$s(604800,wk) $s(86400,day) $s(3600,hr) $s(60,min) $s(1,sec))
    s %x = $int($calc(%t /$1)) | %t = %t % $1 | if (%x) return %x $+ $2 $+ $iif(%x > 1,s)
    

    How he did it:

  • He created the $s() identifier, which saved a lot of space since there was no code that was repeated.
  • Since he stored the seconds in global %t and saved the calculations (%t = %t % $1), he didn't have to do several calculations on $1 over and over.
  • He used $+ $iif(%x > 1,s) inside of the $s() identifier, which made appending the trailing "s" use little space.


  • Runners Up
    1. dreamer1 (194 bytes)
    2. Rich (199 bytes)
    3. peppie (211 bytes)
    4. shikkie (224 bytes)
    5. tronicer (316 bytes)
    6. OndReke (364 bytes)
    7. Lathiat (411 bytes)
    8. Zane (415 bytes)
    9. Galak (423 bytes)
    10. praetorian (448 bytes)
    11. nix (546 bytes)
    12. snu (572 bytes)

    Invalid Entries
    • plazable (183 bytes)
      Number Failed: 1000000
      $duration: 1wk 4days 13hrs 46mins 40secs
      $dur: 1wks 4days 13hrs 46mins 40secs

    • Kamek (185 bytes)
      Number Failed: 604800
      $duration: 1wk
      $dur: 0secs

    • ^ASM^ (193 bytes)
      Number Failed: 604800
      $duration: 1wk
      $dur: 1wk 0secs

    • Variant (194 bytes)
      Number Failed: 00
      $duration: 0secs
      $dur:

    • Eric^^ (195 bytes)
      Number Failed: 1000000
      $duration: 1wk 4days 13hrs 46mins 40secs
      $dur: 1wk 4days 14hrs

    • ZaTi (218 bytes)
      Number Failed: 604800
      $duration: 1wk
      $dur: 6days 23hrs 59mins 60secs

    • LZ (219 bytes)
      Number Failed: 604800
      $duration: 1wk
      $dur: 1wk 0secs

    • Jimmy_RAY_Vaughan (220 bytes)
      Number Failed: 1062101
      $duration: 1wk 5days 7hrs 1min 41secs
      $dur: 1wk 4days 13hrs 46mins 40secs 1wk 5days 7hrs 1min 41secs 1wk 5days 7hrs 1min 41secs

    • jos (228 bytes)
      Number Failed: 00
      $duration: 0secs
      $dur:

    • Allied (232 bytes)
      Number Failed: 604801
      $duration: 1wk 1sec
      $dur: 604801s 0

    • trunks (340 bytes)
      Number Failed: 0
      $duration: 0secs
      $dur:

    • syntheros (379 bytes)
      Number Failed: 1000000
      $duration: 1wk 4days 13hrs 46mins 40secs
      $dur:

    • swarm (397 bytes)
      Number Failed: 1000000
      $duration: 1wk 4days 13hrs 46mins 40secs
      $dur: 1wk 4s 13hrs 46mins 40secs

    • t0m (403 bytes)
      Number Failed: 00
      $duration: 0secs
      $dur:

    • nektrataal (473 bytes)
      Number Failed: 0
      $duration: 0secs
      $dur: 0sec

    • Oxigun (480 bytes)
      Number Failed: 1000000
      $duration: 1wk 4days 13hrs 46mins 40secs
      $dur: 1wk 11days 13hrs 46hrs 40secs

    • Sprocket^ (894 bytes)
      Number Failed: 1000000
      $duration: 1wk 4days 13hrs 46mins 40secs
      $dur:

    • VooDooMoN (1039 bytes)
      Number Failed: 604799
      $duration: 6days 23hrs 59mins 59secs
      $dur: 6days 23hrs 59mins

    • intrage (1275 bytes)
      Number failed: 0
      $duration: 0secs
      $dur:

    Notes: Some entries may fail on more than just the number listed -- testing was stopped the first time it failed. Also, entries that were invalid may not have the exact byte size shown, due to mIRC possibly adding extra whitespace.