MathDB
Compute the sum $a_1+a_2+\ldots+a_{2015}.$

Source: Albania JTST 2015

October 4, 2023

Problem Statement

For every positive integer nn{} denote ana_n as the last digit of the sum of the number from 11 to nn{}. For example a5=5,a6=1.a_5=5, a_6=1. a) Find a21.a_{21}. b) Compute the sum a1+a2++a2015.a_1+a_2+\ldots+a_{2015}.