>: 1<2;
into Hope. Hope replies:

>> true : bool
This means the value of 1<2 is true and the type of 1<2 is bool which is short for boolean.

Now try:

>: 1>2;
Hope replies:
>> false : bool
This means the value of 1>2 is false and the type of 1>2 is boolean.

The values true and false are the only values whose type is boolean. Every boolean expression evaluates to either true or false.

Sebastian Danicic BSc MSc PhD (Reader in Computer Science)
Dept of Computing, Goldsmiths, University of London, London SE14 6NW
Last updated 2010-12-29