71. What is the lifetime of the element in container?
72. What will be the output of the following C++ code?
#include <iostream>
#include <vector>
using namespace std;
int main()
{
vector<int> v;
for (int i = 1; i <= 5; i++)
v.push_back(i);
vector<int> :: const_iterator i;
for (i = v.begin(); i != v.end(); ++i)
cout << *i << " ";
cout<<endl;
return 0;
}
#include <iostream>
#include <vector>
using namespace std;
int main()
{
vector<int> v;
for (int i = 1; i <= 5; i++)
v.push_back(i);
vector<int> :: const_iterator i;
for (i = v.begin(); i != v.end(); ++i)
cout << *i << " ";
cout<<endl;
return 0;
}73. What type of Iterator i1 is in the following C++ code snipet?
================ code ================
vector<int>::iterator i1;
for (i1=v1.begin();i1!=v1.end();++i1)
*i1 = 1;
======================================
================ code ================
vector<int>::iterator i1;
for (i1=v1.begin();i1!=v1.end();++i1)
*i1 = 1;
======================================74. How many adaptors support the checked iterators?
75. What will happen when we move to try block far away from catch block?
76. What is the full form of vptr?
77. Which type of list a List sequence container implements?
78. Which is used to allocate and deallocate storage for objects during the execution?
79. Which of the following function(s) is/are used to get the size of the array class?
80. What happens if a pair is not initialized?
Read More Section(C plus plus miscellaneous)
Each Section contains maximum 100 MCQs question on C plus plus miscellaneous. To get more questions visit other sections.
- C plus plus miscellaneous - Section 1
- C plus plus miscellaneous - Section 2
- C plus plus miscellaneous - Section 3
- C plus plus miscellaneous - Section 4
- C plus plus miscellaneous - Section 5
- C plus plus miscellaneous - Section 6
- C plus plus miscellaneous - Section 7
- C plus plus miscellaneous - Section 9
- C plus plus miscellaneous - Section 10
- C plus plus miscellaneous - Section 11
