String Index of

if i have a String str=“hello”;
And
i write
if(str.indexof(“bye”)>=0)
{
syso(str);
}

it print the string while "bye " is not present in “hello”,
WHY?

Hey @RULEREMPIRES
You are doing something else send me your code