15 views

HOW TO APPROACH IN A LESS TIME CONSUMING WAY?

ago | 15 views
0
$220$ ?
0
yupp

+1
I just observed how the loops are working. Once we could figure it out, the calculation takes $1$ min. Overall we can do it under $3$ mins
$\sum_{i=1}^{10}i+\sum_{i=1}^{9}i+\sum_{i=1}^{8}i+\sum_{i=1}^{7}i+\sum_{i=1}^{6}i+\sum_{i=1}^{5}i+\sum_{i=1}^{4}i+\sum_{i=1}^{3}i+\sum_{i=1}^{2}i+\sum_{i=1}^{1}i$

$=55+45+36+28+21+15+10+6+3+1=220$
0
A very good approach to a question that can cause great panic at first glance.