HP Pascal/iX Reference Manual (31502-90022)

9- 24
r: rec_type;
p: ^rec_type;
a: ARRAY [1..10] OF integer;
pac: PACKED ARRAY [1..10] OF char;
pab: PACKED ARRAY [1..10] OF boolean;
PROCEDURE pro;
BEGIN
END;
FUNCTION f: integer;
BEGIN
END;
Calls
waddress(n)
waddress(r)
waddress(r.f2)
waddress(p)
waddress(p^)
waddress(p^.f2)
waddress(a)
waddress(a[4])
waddress(pac)
waddress(pac[3]) { Legal since component type is char. }
waddress(pab)
waddress(pab[3]) { Error. }
waddress(pro)
waddress(f)
Arithmetic Functions
The eight standard
arithmetic functions
in HP Pascal are abs, arctan,
cos, exp, ln, sin, sqr, and sqrt. Details about each of these functions
are given in the following pages.
abs
Usage
abs
(x)
Argument
x
A numeric expression.
Description
The abs function computes the absolute value of its argument, which must
be an expression with a numeric type. The type of the result is the same
as the type of the numeric expression. Note that it may be an error to
take the absolute value of minint.
Example
Input Result
abs(-13) 13 { integer result }
abs(-7.11) 7.110000E+00
abs (true) error { not a numeric type }
arctan
Usage
arctan
(x)
Argument