login  home  contents  what's new  discussion  bug reports     help  links  subscribe  changes  refresh  edit

Boot is used internally in Axiom for some of the interpreter and compiler code. Here is a detailed description of the Boot Language

This is a simple example of Boot programming.

Define a function.

boot
pairBoot(a,b) ==
  a>b => [-b,-a]
  [a,b]
boot
Value = T
Value = 432

Now call it.

axiom
pairBoot(1,4)$Lisp
LatexWiki Image(1)
Type: SExpression?
axiom
map(integer,destruct(pairBoot(3,2)$Lisp))
LatexWiki Image(2)
Type: List Integer

That's my first Boot function!

You can now write for example:

boot
foobar(x,y) == x + y
boot
Value = T
Value = 304

And call it with

axiom
integer(foobar(2,3)$Lisp)
LatexWiki Image(3)




subject:
  ( 7 subscribers )  
Please rate this page: