Question about the choice of code

When I wrote my code I originally put:

It seems to me that it works exactly as it should. Now I’m wondering whether it is any more or less beneficial to use that compared to what was done in the video. To me it looks like it would be better because in the second IF statement the compiler would compare the two characters rather than just the position in their strings and since the point is to check if the characters are the same that just provides some extra insurance.

“extra insurance” isn’t needed since that code wouldn’t execute if those letters weren’t the same. Also accessing the contents of each string would be an additional operation.

Ahh okay thanks for that!