xref: /freebsd/contrib/bc/tests/bc/scripts/globals.bc (revision ec0ea6efa1ad229d75c394c1a9b9cac33af2b1d3)
1#! /usr/bin/bc -gq
2
3if (!global_stacks()) {
4	sqrt(-1)
5}
6
7define i(x) {
8	ibase=x
9	return ibase
10}
11
12define o(x) {
13	obase=x
14	return obase
15}
16
17define r(x) {
18	scale=x
19	return scale
20}
21
22i(11)
23ibase
24o(12)
25obase
26r(15)
27scale
28