Hello and welcome to our community! Is this your first visit?
Register
Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 7 of 7
  1. #1
    Master Coder
    Join Date
    Feb 2003
    Location
    UmeŚ, Sweden
    Posts
    5,575
    Thanks
    0
    Thanked 83 Times in 74 Posts

    CHALLENGE: The 2004 summer challenge

    In an hour I'll be gone for the most of the summer, but before then, I challenge all JavaScript experts here with something that will be more than a little tricky:

    Your reference for this will be The Unlambda Programming Language.

    Unlambda is a small language with a deciviously simple looking set of commands. It's a purely functional language (purely functional not in the sense of Haskell, but in the sense of the fact that the only constructs in it are functions) without a lambda expression.

    So, my challenge is the following

    Create a function constructor which:
    - Takes an Unlambda 2 program as a single string argument
    - Returns a function

    The returned function must:
    - Execute the Unlambda program when run
    - Take a string argument to simulate STDIN input, or alternatively prompt the user for input.
    - Return an array consisting of the evaluation of the Unlambda program and a string representing the STDOUT output, alternatively returning just the evaluation and instead alerting the output.
    Last edited by liorean; 06-11-2004 at 06:50 PM.
    liorean <[lio@wg]>
    Articles: RegEx evolt wsabstract , Named Arguments
    Useful Threads: JavaScript Docs & Refs, FAQ - HTML & CSS Docs, FAQ - XML Doc & Refs
    Moz: JavaScript DOM Interfaces MSDN: JScript DHTML KDE: KJS KHTML Opera: Standards

  • #2
    New Coder
    Join Date
    Nov 2003
    Posts
    65
    Thanks
    0
    Thanked 0 Times in 0 Posts
    And the prize is????

  • #3
    jkd
    jkd is offline
    Senior Coder jkd's Avatar
    Join Date
    May 2002
    Location
    metro DC
    Posts
    3,163
    Thanks
    1
    Thanked 18 Times in 18 Posts
    A sense of achievement.

    I'd attempt this, but it's a lot of work for a "useless" script (I use the term loosely)... like a lot of work. It's not a challenge as much as writing an entire interpretter in Javascript.... ugh. Even doing ones for limited subsets of assembly took me way too much time and effort.

  • #4
    Master Coder
    Join Date
    Feb 2003
    Location
    UmeŚ, Sweden
    Posts
    5,575
    Thanks
    0
    Thanked 83 Times in 74 Posts
    Well, I was hoping to see what you could do, Jason, but oh well. I'm currently rewriting the one I created for performance, but I'll soon post mine.
    liorean <[lio@wg]>
    Articles: RegEx evolt wsabstract , Named Arguments
    Useful Threads: JavaScript Docs & Refs, FAQ - HTML & CSS Docs, FAQ - XML Doc & Refs
    Moz: JavaScript DOM Interfaces MSDN: JScript DHTML KDE: KJS KHTML Opera: Standards

  • #5
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    Welcome back from your summer disconnect
    Check out the Forum Search. It's the short path to getting great results from this forum.

  • #6
    Master Coder
    Join Date
    Feb 2003
    Location
    UmeŚ, Sweden
    Posts
    5,575
    Thanks
    0
    Thanked 83 Times in 74 Posts
    Quote Originally Posted by Roy Sinclair
    Welcome back from your summer disconnect
    Thanks. I see you took the chance to pass me in the posting league, just when I had gained a comfortable lead...
    liorean <[lio@wg]>
    Articles: RegEx evolt wsabstract , Named Arguments
    Useful Threads: JavaScript Docs & Refs, FAQ - HTML & CSS Docs, FAQ - XML Doc & Refs
    Moz: JavaScript DOM Interfaces MSDN: JScript DHTML KDE: KJS KHTML Opera: Standards

  • #7
    Senior Coder
    Join Date
    Jun 2002
    Location
    Wichita
    Posts
    3,880
    Thanks
    0
    Thanked 0 Times in 0 Posts
    I've been very busy this summer or that might have been a huge lead, you're fast though. I expect you'll probably pass me again before next summer.
    Check out the Forum Search. It's the short path to getting great results from this forum.


  •  

    Posting Permissions

    • You may not post new threads
    • You may not post replies
    • You may not post attachments
    • You may not edit your posts
    •