I am currently learning JavaScript where I found a problem that is confusing me. I tried to test "hello".indexOf("h") and the output showed 0 which is logical. However, when I tried this "hello".indexOf("") , the output showed 0 . How can an empty string's index is as same as the first letter?