function p=polozaj(x) tablica; n=length(X); if x X(n-1) p=2; else p=0; end end