function [t,u] = zpetnaEulerovaMetoda(f,u0,h,t0,N)

t = t0:h:(t0+h*N);
u = t; u(:) = 0;

u(1) = u0;
for n=1:N
    fn = @(uu) u(n)+h*f(t(n+1),uu)-uu;
    u(n+1) = fsolve(fn,u(n));
end
