Write a JAVA program to accept a character and check whether it is a letter, digit or a special character.
Answers
Answered by
0
This are the characters of JAVA.
Attachments:
Answered by
0
Answer:
All characters whether alphabet, digit or special character have ASCII value. Input character from the user will determine if it’s Alphabet, Number or Special character.
ASCII value ranges-
For capital alphabets 65 – 90
For small alphabets 97 – 122
For digits 48 – 57
Examples :
Input : 8
Output : Digit
Input : E
Output : Alphabet
Similar questions