-1,2,-4,8,-16,32,.,512的和

问题描述:

-1,2,-4,8,-16,32,.,512的和

1+2+4+8+16+32+64+128+256+512+1024
=2^0+2^1+2^2+2^3+2^4+2^5+2^6+2^7+2^8+2^9+2^10
令s=2^0+2^1+2^2+2^3+2^4+2^5+2^6+2^7+2^8+2^9+2^10
2s=2^1+2^2+2^3+2^4+2^5+2^6+2^7+2^8+2^9+2^10+2^11
2s-s=2^11-2^0
s=2^11-1
s=2048-1
s=2047
即1+2+4+8+16+32+64+128+256+512+1024 =2047是-1,2,-4,8,-16,32,..........,512的和啊,(你所讲的是1+2+4...........1024的和)