← Back to Question List
C++ Code Walkthrough #37
Comma Operator
📄 Code
Read carefully — what does this print?1#include <iostream>2using namespace std;3int main() {4 int x = (1, 2, 3);5 int y = 5;6 y = (y += 2, y * 2);7 cout << x << " " << y << endl;8 return 0;9}