blob: 5815ea02075cdf5687d1c8b5f3ccdb6ed4945159 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
|
scale=2
print "\nCheck book program!\n"
print " Remember, deposits are negative transactions.\n"
print " Exit by a 0 transaction.\n\n"
print "Initial balance? "; bal = read()
bal /= 1
print "\n"
while (1) {
"current balance = "; bal
"transaction? "; trans = read()
if (trans == 0) break;
bal -= trans
bal /= 1
}
quit
|