Well, for that function you get the LEFT.
I REALLY HOPE THIS ISNT A SCHOOL PROJECT.
So lets take a look at what happened:
=If(logic test, true, false)
So we then nested in the LEFT Method, that says look at the cell, and return the LEFT MOST 5 characters in the logical test of the IF. So if the left most matches, it returns a true.
So in the True column of the first IF statement, we have to run what happens when it is true.
SO we then look at the whole value of the cell, and match it completely, nested within another if statement.
Please understand, you can use RIGHT to check the right most for trailing characters, also.