B = 2^20 - ( 2^19 + 2^18 + 2^17 + ... + 2^1 + 2^0
B = (2^19 x 2 - 2^19) - 2^18 - 2^17 - ... - 2^1 - 0
B = (2^18 x 2 - 2^18) - 2^17 - 2^16 - ... - 2^1 - 0
B = (2^17 x 2 - 2^17) - 2^16 - 2^15 - ... - 2^1 - 0
Cứ tách xong lại đóng ngoặc cho đến:
B = 2^1 x 2 - 2^1 - 0
B = 2^1 - 0
B = 2
Đặt A=219+218+...+20
2A=2(219+218+...+1)
2A=220+219+...+2
2A-A=(220+219+...+2)-(219+218+...+2)
A=220-2
Thay A vào B ta có: 220-(220-2)
=220-220+2
=0+2=2
Đặt A=219+218+...+20
2A=2(219+218+...+1)
2A=220+219+...+2
2A-A=(220+219+...+2)-(219+218+...+2)
A=220-2
Thay A vào B ta có: 220-(220-2)
=220-220+2
=0+2=2
Đặt A=219+218+...+20
2A=2(219+218+...+1)
2A=220+219+...+2
2A-A=(220+219+...+2)-(219+218+...+2)
A=220-2
Thay A vào B ta có: 220-(220-2)
=220-220+2
=0+2=2