ASCII codes for characters and numbers in C++

ASCII means American Standard Code for Information Interchange(a character encoding scheme means uppercase letters(A-Z), lowercase letters(a-z), special symbols($,&,#,@).

 

It control characters to the numbers ranging from 0-225.

#include<iostream.h>

#include<conio.h>

  int main()

   {

      char cha;

      clrscr();

      cout<<"Enter any character";

      cin>>cha;

      if(cha>=48 && cha<=57)

      cout<<"  digit (number 0-9)"<<endl;

     

      else if(cha>=65 && cha<=90)

      cout<<"  capital A-Z"<<endl;

     

      else if(cha>=97 && cha<=122)

      cout<<" small a-z"<<endl;

     else

      cout<<endl<<" special (@#$*) character";

      getch();

      return 0;

}

Output...

ASCII codes

About Us

Rekha SetiaRekha Setia is a passionate blogger of Extra Computer Notes. if you have any ideas or any request me @