CPA-21-02

Review 40 CPA-21-02 practice questions with answer explanations and community insights.

Question 1

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

  1. It prints: 4
  2. It prints: 1
  3. It causes a compilation error
  4. It prints: 0

Question 2

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

  1. It prints: 1
  2. It causes a compilation error
  3. It prints: –1
  4. It prints: 0

Question 3

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

  1. It causes a compilation error
  2. It prints: 9.9
  3. It prints garbage characters
  4. It prints: 9

Question 4

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

  1. It prints: 5.2110.0
  2. It prints: 5.210.0
  3. It prints: 52.10
  4. It prints: 5210

Question 5

What is the expected result of the following program?

  1. It prints: ABCD
  2. It prints: ACBD
  3. It prints: ACDB
  4. It prints: CABD
We are moving to a new platform

CertificationTest is being migrated. Some pages may be slow or briefly unavailable; everything will be back to normal within a few hours. If you run into any issue, email support@certificationtest.net.