1

This is silly, I did the parsing engine, the locate, straight forward. However, I have no idea what I am supposed to do for indexes. Yes, I read the instructions but they make no sense.

"that the function, given a /path/to/a/directory, returns /path/to/a/directory/index.php if index.php actually exists therein,"

Well, if it exist already, what am I to do...???

I know, silly, probably not seeing the forest for the trees but.....

1 Answer 1

2

If it exists, you simply have to return its path, as a string. For example, if the input is the string /gifs/cats, and there is indeed a file named index.html in the /gifs/cats directory, then you should return a string containing /gifs/cats/index.html.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .