The answer to this is irrelevant. What they are looking for in interviews is your thought process. It doesn't matter if you got it wrong or correct...if you got to the solution (or nearly did) using the correct thought process that is what matters to them the most.