At 03:03 +0000 2006/23/3, Sean McGowan wrote:
I'm new to J and have a question regarding tacit functions. I need to write
tacit a J function that takes a list of 3 numbers as its argument.
How do you pass and reference the elements of a list in a function?
The following seems to work when passing one number:
tax 10
1
I wish to pass 3 numbers in a list and be able to use each number in the
computation.
I know list elements can be accessed like this:
list =: 10 0 1
N =: 0 { list
A =: 1 { list
B =: 2 { list
N
10
A
0
B
1
Maybe people are avoiding answering because they think
you are teasing us.... (are you?) Did you try
tax list
1 0 0.1
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm