Ed Keith,


The main thing that I've had difficulty with is how contextually sensitive J 
is. My mistakes have most often been ones of imagining that a certain sequence 
of tokens will have the same meaning when isolated, or when dropped into a 
different situation.

In the step-by-step example provided by Oleg (below), the parentheses around 
the active portion of each line are crucial to keeping the verb-phrasing 
distinct. Without that isolation the J within would mean something quite 
diffierent.

To understand why and how it would be different, and thus to understand what 
the code means in any given situation, you must understand trains.  (Details at 
http://www.jsoftware.com/help/dictionary/dictf.htm
of course.) Tacit coding typically involves a bunch of verbs written together, 
and the logic of tacit trains is such that parameters are fed invisibly into 
the midst of those verbs based on those verbs occuring three-in-a-row (fork) or 
two-in-a-row (hook). In my experience, learning to scan right-to-left for 
verb-triples (forks) was the first skill through which I found I was able to 
think tacitly.

Another thing that seems worth mentioning is that I have found operators 
(adverbs and conjunctions) to be the most interesting aspect of J, and that 
operators have a left-to-right syntactic structure that runs "against the 
grain" of the noun-and-verb parsing rules that everybody learns first. It knits 
together very nicely, but it can take some time to understand.


 Tracy B. Harms



--- Oleg Kobchenko <olegykj at yahoo.com> wrote:



> This is an interesting question: how would

> you think and what are the practices in

> tacit programming.

> 

> 0th you need test cases: what data is input 

> and output.

> 

> First thing different from C++ is that J

> is highly interective, which allow incremental

> experimenting.

> 

> Then you build from bottom up adding more

> operations using parens (...) instead of

> of name.

> 

> Finally, creating names when needed.

> 

>    4 #. 3 2 1   NB. test case

> 57

> 

>    57 (^.~) 4   NB. incremental

> 2.91645

>    57 (1 + ^.~) 4

> 3.91645

>    57 ([: <. 1 + ^.~) 4

> 3

>    57 (] #~ [: <. 1 + ^.~) 4

> 4 4 4

>    57 ([ #:~ ] #~ [: <. 1 + ^.~) 4

> 3 2 1

> 

>                 NB. new name   

>    base=: [ #:~ ] #~ [: <. 1 + ^.~

>    57 base 4

> 3 2 1





       
____________________________________________________________________________________
Take the Internet to Go: Yahoo!Go puts the Internet in your pocket: mail, news, 
photos & more. 
http://mobile.yahoo.com/go?refer=1GNXIC
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to