weight = [60, 58, 59, 57]
D = 4
A = 10

score = A

for i in range(1, D):
    if weight[i] < weight[i-1]:
        score += 1
    elif weight[i] > weight[i-1]:
        score -= 1

print(score)

Embed on website

To embed this project on your website, copy the following code and paste it into your website's HTML: