Thanks. I did try that but for some reason thought it hadn't worked! On a vaguely related note, if I have a fraction, e.g. 999r1000, how can I isolate the numerator and denominator? I was thinking of formatting as a string, and then I can do this:
'r' i. ":999r1000 1 1 1 0 1 1 1 1 I was hoping to be able to go from there to by knowing where the 'r' is, but I can't think of how to do it. I'm still finding it hard to stop thinking like it's C. On 12 Sep 2011, at 14:08, Raul Miller wrote: > On Mon, Sep 12, 2011 at 8:57 AM, David Vaughan > <purpleblue...@googlemail.com> wrote: >> I'm trying to achieve this calculation: >> %1+%2+%1+%1+%4+%1... >> >> Essentially I want to insert +% in between each item in a list. I thought >> this could be achieved with / or @ but I seem to be wrong. >> >> Any help would be appreciated. > > (+%)/1 2 1 1 4 1 > 1.39286 > %(+%)/1 2 1 1 4 1 > 0.717949 > > -- > Raul > ---------------------------------------------------------------------- > For information about J forums see http://www.jsoftware.com/forums.htm ---------------------------------------------------------------------- For information about J forums see http://www.jsoftware.com/forums.htm