[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Axiom-math] What is the "+/" operator?
From: |
Bill Page |
Subject: |
Re: [Axiom-math] What is the "+/" operator? |
Date: |
Wed, 23 May 2007 13:43:20 -0400 |
User-agent: |
Webmail 4.0 |
Quoting Ralf Hemmecke <address@hidden>:
...
But if you like the
f/[a,b,c]
syntax, you can actually define a similar things in Aldor. (I guess,
SPAD would be just the same.)
That's cool, Ralf.
Take a look at this in the Axiom interpreter:
(1) -> Z ==> Integer
Type: Void
(2) -> /: ((Z, Z) -> Z, List Z) -> Z
Type: Void
(3) -> _/(f: (Z, Z) -> Z,l: List Z): Z == ( empty? l => 0; f(first l, f/(rest
l)))
Function declaration ?/? : (((Integer,Integer) -> Integer),List
Integer) -> Integer has been added to workspace.
Type: Void
(4) -> (+)/[1,2,3]
Compiling function / with type (((Integer,Integer) -> Integer),List
Integer) -> Integer
(4) 6
Type: PositiveInteger
--------
Regards,
Bill Page.
- [Axiom-math] What is the "+/" operator?, Igor Khavkine, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?, Martin Rubey, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?, Bill Page, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?, Ralf Hemmecke, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?,
Bill Page <=
- Re: [Axiom-math] What is the "+/" operator?, Gabriel Dos Reis, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?, Ralf Hemmecke, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?, Gabriel Dos Reis, 2007/05/23
- Re: [Axiom-math] What is the "+/" operator?, Ralf Hemmecke, 2007/05/24
- Re: [Axiom-math] What is the "+/" operator?, Gabriel Dos Reis, 2007/05/24
- Re: [Axiom-math] What is the "+/" operator?, Gabriel Dos Reis, 2007/05/23
Re: [Axiom-math] What is the "+/" operator?, Gabriel Dos Reis, 2007/05/23