Mathedu Courses logo

Mathedu Courses

If you see this, something is wrong

Table of contents

First published on Monday, Feb 23, 2026 and last modified on Tuesday, Feb 24, 2026

Test Section 3

Fabienne Chaplais Email

1 Exercise

def sum(n):
# calculate the sum of the integers between 0 and n
    s=0
    if n>0:
        for i in range(1,n+1):
            s=s+i
    return(s)

Discussion: login to participate.