def solution(n):
cnt = 0
for i in range(1, n+1):
sum = 0
for j in range(i, n+1):
sum = sum + j
if (sum >= n):
break
if (sum == n):
cnt += 1
return cnt
def solution(n):
cnt = 0
for i in range(1, n+1):
sum = 0
while (sum < n):
sum = sum + i
i = i + 1
if (sum == n):
cnt += 1
return cnt