Live quiz

cpp - Part 13

Question 1 of 25 Hints left: 3
Q1

What will be the output of the following C++ code? #include <iostream> using namespace std; int main() { int x = -1; unsigned int y = 2; if(x > y) { cout << "x is greater"; } else { cout << "y is greater"; } }

  • A
  • B
  • C
  • D