What will be the output of the following C++ code?
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main(int argc, char const *argv[])
{
vector <int> v = {1,5,23,90,15,35};
make_heap(v.begin(),v.end());
cout<<v.front();
}
#include <iostream>
#include <vector>
#include <algorithm>
using namespace std;
int main(int argc, char const *argv[])
{
vector <int> v = {1,5,23,90,15,35};
make_heap(v.begin(),v.end());
cout<<v.front();
}A. 23
B. 1
C. 35
D. 90
Answer: Option A

Join The Discussion