Here's console interpreter with the usual
prompt/read/eval/print loop.

   prompt=: stdout@('   '"_)
   read=: 1!:[EMAIL PROTECTED]: :. echo
   eval=: '[' , ,&']'          NB. your interpreter here

   (eval&.read)@prompt ''      NB. single execution
   2+3
[2+3]
   
   (eval&.read)@prompt^:10 ''  NB. loop
   12
[12]
   13
[13]
   14
[14]



 
____________________________________________________________________________________
Food fight? Enjoy some healthy debate 
in the Yahoo! Answers Food & Drink Q&A.
http://answers.yahoo.com/dir/?link=list&sid=396545367
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to