Today, the IT industry is facing fierce competition, you will feel powerless, this is inevitable. All you have to do is to escort your career. Of course, you have many choices. I recommend that you use the IT-Tests.com C++ Institute CPP exam questions and answers, it is a good helper to help your success of IT certification. So what you still waiting for, go to get new IT-Tests.com C++ Institute CPP exam training materials early.
IT-Tests's providing training material is very close to the content of the formal examination. Through our short-term special training You can quickly grasp IT professional knowledge, and then have a good preparation for your exam. We promise that we will do our best to help you pass the C++ Institute certification CPP exam.
C++ Institute CPP is a certification exam to test IT professional knowledge. IT-Tests.com is a website which can help you quickly pass the C++ Institute certification CPP exams. Before the exam, you use pertinence training and test exercises and answers that we provide, and in a short time you'll have a lot of harvest.
Exam Code: CPP
Exam Name: C++ Institute (C++ Certified Professional Programmer)
Our latest training material about C++ Institute certification CPP exam is developed by IT-Tests's professional team's constantly study the outline. It can help a lot of people achieve their dream. In today's competitive IT profession, if you want to stabilize your own position, you will have to prove your professional knowledge and technology level. C++ Institute certification CPP exam is a very good test to prove your ability. If you have a C++ Institute CPP certification, your work will have a lot of change that wages and work position will increase quickly.
CPP (C++ Certified Professional Programmer) Free Demo Download: http://www.it-tests.com/CPP.html
NO.1 What happens when you attempt to compile and run the following code?
#include <list>
#include <iostream>
using namespace std;
template<class T> void print(T start, T end) {
while (start != end) {
std::cout << *start << " "; start++;
}
}
class A {
int a;
public:
A(int a):a(a){}
operator int () const { return a;}int getA() const { return a;}
};
int main() {
int t1[] ={ 1, 2, 3, 4, 5, 6, 7, 8, 9, 10};
list<A> l1(t1, t1 + 10);
list<A> l2(l1);
l2.reverse(); l1.splice(l1.end(),l2);
l1.pop_back();l1.unique();
print(l1.begin(), l1.end()); cout<<endl;
return 0;
}
A. compilation error
B. runtime exception
C. program outputs: 1 2 3 4 5 6 7 8 9 10 9 8 7 6 5 4 3 2
D. program outputs: 1 2 3 4 5 6 7 8 9 10 10 9 8 7 6 5 4 3 2
E. program outputs: 1 2 3 4 5 6 7 8 9 10 9 8 7 6 5 4 3 2 1
Answer: C
C++ Institute original questions CPP CPP
NO.2 What happens when you attempt to compile and run the following code?
#include <iostream>
#include <algorithm>
#include <vector>
using namespace std;
class A {
int a;
public:
A(int a) : a(a) {}
int getA() const { return a; } void setA(int a) { this?>a = a; }
bool operator==(const A & b) const { return a == b.a; }
};
bool compare(const A & a, const A & b) { return a == b; }
int main () {
int t[] = {1,2,3,3,5,1,2,4,4,5};
vector<A> v (t,t+10);
vector<A>::iterator it = v.begin();
while ( (it = adjacent_find (it, v.end(), compare)) != v.end()) {
cout<<it?v.begin()<<" ";it++;
}
cout<< endl;
return 0;
A. program outputs: 2 3
B. program outputs: 2 7
C. program outputs: 3 8
D. compilation error
E. program will run forever
Answer: B
C++ Institute test CPP CPP CPP CPP test questions
NO.3 What happens when you attempt to compile and run the following code?
#include <vector>
#include <iostream>
#include <algorithm>
using namespace std;
template<class T>struct Out {
ostream & out;
Out(ostream & o): out(o){}
void operator() (const T & val ) { out<<val<<" "; } };
struct Add {
int operator()(int & a, int & b) {
return a+b;
}
};
int main() {
int t[]={1,2,3,4,5,6,7,8,9,10};
vector<int> v1(t, t+10);
vector<int> v2(10);
transform(v1.begin(), v1.end(), v2.begin(), bind1st(1,Add()));
for_each(v2.rbegin(), v2.rend(), Out<int>(cout));cout<<endl;
return 0;
}
Program outputs:
A. 1 2 3 4 5 6 7 8 9 10
B. 2 3 4 5 6 7 8 9 10 11
C. 10 9 8 7 6 5 4 3 2 1
D. 11 10 9 8 7 6 5 4 3 2
E. compilation error
Answer: E
C++ Institute CPP CPP CPP original questions
Are you still worrying about the high difficulty to pass C++ Institute certification CPP exam? Are you still sleeplessly endeavoring to review the book in order to pass C++ Institute CPP exam certification? Do you want to pass C++ Institute CPP exam certification faster? Be quick to select our IT-Tests! Having it can quickly fulfill your dreams.
没有评论:
发表评论