Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!linus!philabs!cmcl2!seismo!caip!princeton!allegra!alice!ark From: ark@alice.UucP (Andrew Koenig) Newsgroups: net.lang.apl Subject: Re: APL structure Message-ID: <5575@alice.uUCp> Date: Mon, 2-Jun-86 11:33:51 EDT Article-I.D.: alice.5575 Posted: Mon Jun 2 11:33:51 1986 Date-Received: Wed, 4-Jun-86 07:33:59 EDT References: <1517@mmintl.UUCP> Organization: Bell Labs, Murray Hill Lines: 25 >Could you explain what you mean by this? What is "direct definition"? Direct definition is where you type identifier: expression and that defines a function named "identifier." Any variables assigned in the expression are made local. Arguments are referred to by the alpha and omega symbols for left and right arguments, respectively. For a monadic function you can use all alpha or all omega. So: SQRT:alpha*0.5 You can also write identifier: e1 : e2 : e3 where e1, e2, e3 are expressions. This means the value of the function is e1 unless e2 is true, in which case it's e3. Thus: FACT: alpha x FACT alpha-1 : alpha=0 : 1 Note that colon is not a function -- it effectively has lower precedence than function symbols.