I knew a bunch and couldn't remember one!  A good story!

Thanks,  Linda

-----Original Message-----
From: programming-boun...@jsoftware.com
[mailto:programming-boun...@jsoftware.com] On Behalf Of Roger Hui
Sent: Sunday, May 06, 2012 2:53 AM
To: Programming forum
Subject: Re: [Jprogramming] (no subject)

You can do this the same as you do in APL, ''$,34.

I remember discussing this with Fred Appleyard when I was a summer student
in IPSA Calgary in 1975.  I opined that you "can not make a scalar from a
vector".  He immediately showed me ''$,34, (,34)[0], +/,34, etc.



On Sat, May 5, 2012 at 11:46 PM, Linda Alvord
<lindaalv...@verizon.net>wrote:

> J Vocabulary, Primer, Single atom array
>
> An array with a single atom is referred to as a singleton. All 
> singletons with the same atom display the same way. However, the fact 
> that they have different ranks affects how verbs act on them. This can 
> be a pitfall for beginners. It is important to remember that if it 
> displays like an atom, but does not behave like one, then check its 
> rank.
>
> Is there somewhere in the vocabulary where it mentions how to change a 
> single element list to an atom (shape 1 to shape empty)
>
>   $34
>   $,34
> 1
>   #34
> 1
>   #,34
> 1
>
> Isn't the problem with shapes rather than rank?
>
> In any case, I have a mental lapse and can't seem to change  ,34  to  34 .
>
> Thanks in advance.
>
> Linda
>
> ----------------------------------------------------------------------
> For information about J forums see http://www.jsoftware.com/forums.htm
>
----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

----------------------------------------------------------------------
For information about J forums see http://www.jsoftware.com/forums.htm

Reply via email to