fork download
  1. #include <iostream>
  2. #define DEBUG_MACRO(name) cout << #name << " = " << name << endl;
  3. using namespace std;
  4. int main() {
  5. int bar = 9;
  6. char foo = 'z';
  7. DEBUG_MACRO(bar);
  8. DEBUG_MACRO(foo);
  9. }
Success #stdin #stdout 0.02s 2680KB
stdin
Standard input is empty
stdout
bar = 9
foo = z