Sololearn: Learn to Code
+ 15
char c = 'a'; int ascii = (int)c; // type-casting cout<<ascii<<endl; // Or directly cout<<(int)'a'<<endl;
7th Apr 2017, 12:18 PM
Shamima Yasmin
Shamima Yasmin - avatar