To check the given input is alphabet or number of special character. (Qbasic Code)

To check the given input is alphabet or number of special character. (Qbasic Code)
  • CLS
    INPUT "Enter any input"; ch$
    ch$ = LCASE$(ch$)
    IF ch$ >= "0" AND ch$ <= "9" THEN
        PRINT "The input is number"
    ELSEIF ch$ >= "a" AND ch$ <= "z" THEN
        PRINT "The input is alphabet"
    ELSE
        PRINT "The input is special character"
    END IF
    END

Share :

Twitter
Back To Top

facebook main

counter

Powered by Blogger.