Deal of The Day! Hurry Up, Grab the Special Discount - Save 25% - Ends In 00:00:00 Coupon code: SAVE25
Welcome to Pass4Success

- Free Preparation Discussions

C++ Institute CPA - C++ Certified Associate Programmer Exam

Certification Provider: C++ Institute
Exam Name: CPA - C++ Certified Associate Programmer
Duration: 65 Minutes
Number of questions in our database: 220
Exam Version: Apr. 13, 2024
Exam Official Topics:
  • Topic 1: Defining overloaded operators, user-defined operators, exceptions/ Dealing with classes and objects, class hierarchy and inheritance String as an example of object: introducing methods and properties/ Obtaining the machine code: compilation process
  • Topic 2: Accessing data and dealing with exceptions/ Declaring, defining and invoking functions, function overloading
  • Topic 3: Converting values of different types/ Characters: values, literals, operators
  • Topic 4: Floating point types: values, literals, operators/ Dealing with streams and basic input/output operations
  • Topic 5: Side effects,?different methods of passing parameters and their purpose/ Introduction to compiling and software development
  • Topic 6: Loops and controlling the loop execution/ Declaring and invoking functions
  • Topic 7: Logic, bitwise and arithmetic operators/ Object-oriented approach and its vocabulary
  • Topic 8: Strings: declarations, initializations, assignments/ Machine and high-level programming languages, compilation process
Disscuss C++ Institute CPA - C++ Certified Associate Programmer Topics, Questions or Ask Anything Related

Currently there are no comments in this discussion, be the first to comment!

Free C++ Institute CPA - C++ Certified Associate Programmer Exam Actual Questions

The questions for CPA - C++ Certified Associate Programmer were last updated On Apr. 13, 2024

Question #1

What happens when you attempt to compile and run the following code?

#include

using namespace std;

class A {

public :

void print() {

cout << "A ";

}

};

class B {

public :

void print() {

cout << "B ";

}

};

int main() {

B sc[2];

B *bc = (B*)sc;

for (int i=0; i<2;i++)

(bc++)->print();

return 0;

}

Reveal Solution Hide Solution
Correct Answer: B

Question #2

What will happen when you attempt to compile and run the following code?

#include

using namespace std;

int main (int argc, const char * argv[])

{

enum state { ok, error, warning};

enum state s1, s2, s3;

s1 = ok;

s2 = warning;

s3 = error;

s4 = ok;

cout << s1<< s2<< s3;

return 0;

}

Reveal Solution Hide Solution
Correct Answer: B

Question #3

What happens when you attempt to compile and run the following code?

#include

#include

using namespace std;

int main()

{

string s1[]= {"How" , "to" };

s1[0].swap(s1[1]);

for (int i=0; i<2; i++) {

cout << s1[i];

}

return( 0 );

}

Reveal Solution Hide Solution
Correct Answer: B

Question #4

What happens when you attempt to compile and run the following code?

#include

using namespace std;

int main()

{

const char *s;

char str[] = "Hello";

s = str;

while(*s) {

cout << *s++;

}

return 0;

}

Reveal Solution Hide Solution
Correct Answer: B

Question #5

What is the output of the program if character 3 is supplied as input?

#include

using namespace std;

int main () {

int c;

cin >> c;

try

{

switch (c)

{

case 1:

throw 20;

case 2:

throw 5.2f;

case 3:

throw 'a';

}

}

catch (int e)

{ cout << "int exception. Exception Nr. " << e; }

catch (float e)

{ cout << "float exception. Exception Nr. " << e; }

catch (...)

{ cout << "An exception occurred."; }

return 0;

}

Reveal Solution Hide Solution
Correct Answer: C


Unlock all CPA - C++ Certified Associate Programmer Exam Questions with Advanced Practice Test Features:
  • Select Question Types you want
  • Set your Desired Pass Percentage
  • Allocate Time (Hours : Minutes)
  • Create Multiple Practice tests with Limited Questions
  • Customer Support
Get Full Access Now

Save Cancel