Question PRG-CPP-0070
HardWhat is the output of this program?
#include <iostream>
#include <string>
#include <tuple>
using namespace std;
int main() {
pair<int, string> p{2, "two"};
auto [n, s] = p;
tuple<int, char, double> t{1, 'x', 2.5};
cout << n << s << get<1>(t) << get<2>(t);
return 0;
}
- A.
2twox2
- B.
2twox2.5
- C.
Sign up free to see the answer and a step-by-step explanation.