计算a+[a+b]+[a+2b]+[a+3b]+...+[a+99b]

问题描述:

计算a+[a+b]+[a+2b]+[a+3b]+...+[a+99b]

=a+[a+b]+[a+2b]+[a+3b]+...+[a+99b]
=100a+b+2b+3b+...+99b
=100a+(1+2+3+..+99)*b
=100a+99*(1+99)/2 *b
=100a+4950b