TO CHECK THE CHARACTER IS CAPITAL OR SMALL
DECLARE FUNCTION CHTR$(A$)
CLS
INPUT"ENTER ANY CHARACTER";A$
PRINT CHTR$(C$)
END
FUNCTION CHTR$(A$)
D$=LEFT$(A$)
A=ASC(D$)
IF A>=65 AND A<=90 THEN
CHTR$="LETTER IS IN UPPER CASE"
ELSE IF A>=48 AND A<=57 THEN
CHTR$="LETTER IS IN LOWER CASE"
ELSE
CHTR$="NOT A CHARACTER"
END IF
END FUNCTION
Comments
Post a Comment