So what do you need help with? You show what looks like an almost-working version of length(). indexof() should be a trivial modification of the same logic as your length().
[I say that your length() is “almost” working in that the last line reads “return sayac;” when it should read “return i;”].
What have you got so far for the other functions? What are you stuck on?