Question: trapezoid rule using loop

Dear all

I tried to compute an integral using trapezoidal rule using two differents methods but I get two different results
trap.mw

Thank you for your help 

Please Wait...