if (code=='A' && 'a')
These are not valid statements. You must tell the compiler what the small
a
is being compared against:
if (code=='A' || code=='a')
You also cannot use the AND operator there. A variable cannot be equal to
'A'
and also equal to
'a'
.