Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
J Interpreter written in JavaScript
JavaScript
Branch: master

Fetching latest commit…

Cannot retrieve the latest commit at this time

Failed to load latest commit information.
README
bignumber.js
index.html
jquery-1.3.1.js
jsj.html

README

J Interpreter in JavaScript
===========================

This is a start at an interpreter for the J programming language
written in JavaScript. For more information on J, see:

  http://jsoftware.com/

I wrote it to learn more about the J evaluation model. I followed
the outline of the algorithm from the J Dictionary, Section E:

  http://www.jsoftware.com/help/dictionary/dicte.htm

Very few primitives are currently implemented.

I've made it available on github in case anyone wants to hack on it
and improve it.

Examples
========
Simple examples that work are things like:

  1 2 + 3 4
  (+/%#) 1 2 3 

Different ways of computing factorial
  ! 8
  */1+i.8

Array's
  2 3 $ 5 6 7 8 9 10
  2 2 3 $ 5 6 7 8 9 10
  3 $ 1
  $ (2 3 $ 5 6 7 8)

License
=======
Redistribution and use in source and binary forms, with or without
modification, are permitted provided that the following conditions are met:

1. Redistributions of source code must retain the above copyright notice,
   this list of conditions and the following disclaimer.

2. Redistributions in binary form must reproduce the above copyright notice,
   this list of conditions and the following disclaimer in the documentation
   and/or other materials provided with the distribution.

THIS SOFTWARE IS PROVIDED ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES,
INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND
FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
DEVELOPERS AND CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO,
PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS;
OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY,
WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR
OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF
ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.

Feedback
========
I host this on github:

  http://github.com/doublec/jsj

Feel free to clone, hack away, suggest patches, etc. I can be reached
via email: chris.double@double.co.nz


Something went wrong with that request. Please try again.