summaryrefslogblamecommitdiffstats
path: root/016.bc
blob: 1d30fd97816b6ff302343c846069f0c38c7e7496 (plain) (tree)
1
2
3
4
5
6
7
8
9
10









                     
#!/usr/bin/bc

scale = 0
total = 0
num = 2^1000
while (num > 0) {
    total += num % 10
    num = num / 10
}
total