hackerrank : moving average