Staircase function/Sum/Exercise