The way to look at if statements is like this (it might sound a bit convoluted now, but this will eventually become a natural way to think of it)
In simple terms, false is 0, true is NOT 0…
When you use AND, OR, or NOT operators (&&, || and ! respectively), you’re telling the computer to compare EACH side of that operator, and return based on the results
AND = return true if BOTH sides are true (non-zero)
OR = return true if EITHER side is true (non-zero)
! = return true if statement is false (zero)
So, using that logic with your statement
(Response == ‘y’ || ‘Y’)
‘Y’ is a non-zero value (after all, it’s Y, not 0 )
So, since the || operator tells the program to return true if EITHER side is true (non-zero), your statement would ALWAYS return true. Therefore, even if you typed in a chinese symbol, it would still return true.
That’s why you need to use the full statement
(Response == ‘y’) || (Response == ‘Y’);
Because you need both sides of the statement to do a comparison to your response.
Did that make enough sense?