﻿from math import *

def Distance(xA,yA,xB,yB):
    d=sqrt((xB-xA)**2+(yB-yA)**2)
    return d

def Longueur(a,b,N):
    S=0
    u=a
    for i in range(0,N):
        v=u+(b-a)/N
        S=S+Distance(u,u**2,v,v**2)
        u=v
    return S

