What is the sum: $\displaystyle\sum_{n=0}^{31} 2^n$?
I know the formula is $S_n = \frac{a_1 (1-r^n)}{1-r}$ , so I have $$S_n = \frac{1(1-2^{32})}{1-2} = \frac{-4294967295 }{-1} = 4294967295$$
Is this correct?
Similarly for another sum $\sum_{n=32}^{63} 2^n$ , I have
$$\frac{2^{32}(1-2^{32})}{1-2}$$
Is this correct?
Yes.
For the second one, if you noticed, is just $2^{32}$ times the first sum.