fork download
  1. #include<iostream>
  2. using namespace std;
  3.  
  4.  
  5. int main(){
  6. char ch = 'x';
  7. int num = ch;
  8. cout<<ch<<" => " << num << endl;
  9. ch = 'µ'; // should now have an extended ascii character
  10. num = ch;
  11. cout<<ch<<" => " << num << endl;
  12. cout<<" using unsigned "<< (unsigned int) 'µ';
  13. return 0;
  14. }
Success #stdin #stdout 0s 3468KB
stdin
Standard input is empty
stdout
x => 120
� => -75
 using unsigned 49845