aboutsummaryrefslogtreecommitdiff
path: root/tests/bc/scripts/add_09600.bc
blob: 0b36a67aeff6fd2a0984e5c39431cdef0e0923e0 (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
#! /usr/bin/bc -lq

scale = 20
x = 1234567890 / scale
len = length(x) + 1 + scale
len *= 2

for (i = 0; i <= len; ++i) {
	a[i] = x * (10^i)
	a[i]
}

for (i = 9501; i <= 9600; ++i) {
	for (j = 0; j < len; ++j) {
		a[i] + a[j]
	}
}