fork(1) download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. char a = 'a';
  6. char b = 'ã';
  7. wchar_t c = 'a';
  8. wchar_t d = 'ã';
  9. cout << sizeof(char) << "\n";
  10. cout << sizeof(a) << "\n";
  11. cout << sizeof('a') << "\n";
  12. cout << sizeof(b) << "\n";
  13. cout << sizeof(c) << "\n";
  14. cout << sizeof(d) << "\n";
  15. cout << sizeof('ã') << "\n";
  16. }
  17.  
  18. //https://pt.stackoverflow.com/q/178456/101
Success #stdin #stdout 0s 4252KB
stdin
Standard input is empty
stdout
1
1
1
1
4
4
4