Skip to content
  • Home
  • CCNA Labs
    • CCNA 1 LAB Activities (v6 & v7)
    • CCNA 2 LAB Activities (v6 & v7)
    • CCNA 3 LAB Activities (v6 & v7)
    • CCNA 4 Lab Activities
  • Linux
    • Linux Unhatched
    • Linux Essentials 2.0
    • Linux Essentials
    • Introduction to Linux I
    • Introduction to Linux II
  • Programming
    • PCAP – Programming Essentials in Python
    • CLA – Programming Essentials in C
    • CPA Programming Essentials in C++
  • About
    • Contact Us
    • Privacy Policy

CCNA 7 Exam Answers 2023

Go with our CCIE, Passed 100%

  • ITE
    • ITE - IT Essentials v7.0
    • ITE - IT Essentials v6.0
      • IT Essentials Lab 2019
    • ITE v5.0 Exam
    • Virtual Activity Laptop
    • Virtual Activity Desktop
  • NE
    • MF
  • CCNA
    • CCNA1
      • CCNA1 v7.0 – ITN
      • CCNA1 v6.0
    • CCNA2
      • CCNA2 v7.0 – SRWE
      • CCNA2 v6.0
    • CCNA3
      • CCNA3 v7.0 – ENSA
      • CCNA3 v6.0
    • CCNA4
      • CCNA4 v6.0
  • Cyber-Security
    • ITC – Introduction to Cybersecurity 2.1 (Level 1)
    • CE – Cybersecurity Essentials 1.1 (Level 2)
    • CCNA CyberOps 1.1 (Level 3)
  • Security
    • CCNA Security v2
  • DevNet
  • CCNA PT Lab 2023

CPA Chapter 3 Assessment Online

Last Updated on May 20, 2021 by Admin

CPA Chapter 3 Assessment Online

CPA -- Chapter 3 Assessment

Time limit: 0

Quiz-summary

0 of 20 questions completed

Questions:

  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. 14
  15. 15
  16. 16
  17. 17
  18. 18
  19. 19
  20. 20

Information

CPA — Chapter 3 Assessment

You have already completed the quiz before. Hence you can not start it again.

Quiz is loading...

You must sign in or sign up to start the quiz.

You have to finish following quiz, to start this quiz:

Results

0 of 20 questions answered correctly

Your time:

Time has elapsed

You have reached 0 of 0 points, (0)

Average score
 
 
Your score
 
 

Categories

  1. Not categorized 0%
  1. 1
  2. 2
  3. 3
  4. 4
  5. 5
  6. 6
  7. 7
  8. 8
  9. 9
  10. 10
  11. 11
  12. 12
  13. 13
  14. 14
  15. 15
  16. 16
  17. 17
  18. 18
  19. 19
  20. 20
  1. Answered
  2. Review
  1. Question 1 of 20
    1. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int main() {
            int t[3] = { 3, 2, 1 }, *ptr = t + 1;
            (*(ptr + 1))++;
            *ptr++;
            cout << t[1] << t[2];
            return 0;
        }

    Correct

    Incorrect

  2. Question 2 of 20
    2. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int main() {
            float x = 3.14, *p = &x;
            p[0] = ++x;
            cout << x;
            return 0;
        }

    Correct

    Incorrect

  3. Question 3 of 20
    3. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int main() {
            int tab[5] = { 1, 2, 4, 8, 16 };
            int *p1 = tab, *p2 = tab + 4;
            for(int *p = p1 + 1; p < p2; p++)
                *p = p[-1] * 2;
            cout << tab[1] << tab[2];
            return 0;
        }

    Correct

    Incorrect

  4. Question 4 of 20
    4. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int main() {
            float f[2];
            float *p1 = f, *p2 = p1 + 1;
            cout << (p2 – p1) / sizeof(float);
            return 0;
        }

    Correct

    Incorrect

  5. Question 5 of 20
    5. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        float fun(float arg) {
            return arg * arg + arg + 1;
        }
        
        int main() {
            cout << fun(fun(1.0));
            return 0;
        }

    Correct

    Incorrect

  6. Question 6 of 20
    6. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int fun(float a, float b) {
            return a / b;
        }
        
        int main() {
            cout << fun(fun(1.0,2.0),fun(2.0,1.0));
            return 0;
        }

    Correct

    Incorrect

  7. Question 7 of 20
    7. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        float Float(float x) {
            return 2 * x / (.5 * x);
        }
        
        void Void(int n) {
            float v = n;
            while(n) {
                v = Float(v);
                n >>= 1;
            }
            cout << v;
        }
        
        int main() {
            Void(4);
            return 0;
        }

    Correct

    Incorrect

  8. Question 8 of 20
    8. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int f1(int a) {
            return ++a;
        }
        
        int f2(int &a) {
            return ++a;
        }
        
        int f3(int *a) {
            return *a + 1;
        }
        
        int main() {
            int value = 2;
            cout << f1(value);
            cout << f2(value);
            cout << f3(&value);
            return 0;
        }

    Correct

    Incorrect

  9. Question 9 of 20
    9. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int f1(int *a) {
            return *a;
        }
        
        int *f2(int *a) {
            return a;
        }
        
        int *f3(int &a) {
            return &a;
        }
        
        int main() {
            int value = 2;
            cout << f1(f2(f3(value)));
            return 0;
        }

    Correct

    Incorrect

  10. Question 10 of 20
    10. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int f1(int *a) {
            return *a + 1;
        }
        
        int *f2(int *a) {
            return a + 1;
        }
        
        int *f3(int &a) {
            return &a + 1;
        }
        
        int main() {
            int t[] = {0, 1, 2, 3};
            cout << f1(f3(*f2(t)));
            return 0;
        }

    Correct

    Incorrect

  11. Question 11 of 20
    11. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int fun(int p1 = 1, int p2 = 1) {
            return p2 << p1;
        }
        
        int main() {
            cout << fun(fun(),fun(2));
            return 0;
        }

    Correct

    Incorrect

  12. Question 12 of 20
    12. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        #include <string>
        using namespace std;
        
        string fun(string &t, string s = “”, int r = 2) {
            while(–r)
                s += s;
            t = t + s;
            return s;
        }
        
        int main() {
            string name = “x”;
            cout << fun(name, name);
            cout << name;
            return 0;
        }

    Correct

    Incorrect

  13. Question 13 of 20
    13. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        #include <string>
        using namespace std;
        
        string fun(string t, string s = “x”, int r = 1) {
            while(–r)
                s += s;
            t = t + s;
            return s;
        }
        
        int main() {
            string name = “a”;
            cout << fun(name);
            cout << name;
            return 0;
        }

    Correct

    Incorrect

  14. Question 14 of 20
    14. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int fun(int a, int b) {
            return a + b;
        }
        
        int fun(int a, char b) {
            return b – a;
        }
        
        int fun(float a, float b) {
            return a * b;
        }
        
        int main() {
            cout << fun(1,0) << fun(‘a’,’c’) << fun(2.f,2.f);
            return 0;
        }

    Correct

    Incorrect

  15. Question 15 of 20
    15. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int fun(long a, long b = 1) {
            return a << b;
        }
        
        int fun(int a, char b = ‘z’) {
            return b – a;
        }
        
        int fun(float a, float b = 0) {
            return a * b;
        }
        
        int main() {
            cout << fun(1L) << fun(‘x’) << fun(2e0f);
            return 0;
        }

    Correct

    Incorrect

  16. Question 16 of 20
    16. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int fun(long a) {
            return a / a;
        }
        
        int fun(int a) {
            return 2 * a;
        }
        
        int fun(double a = 3.0) {
            return a;
        }
        
        int main() {
            cout << fun(1000000000L) << fun (1L) << fun(1.f);
            return 0;
        }

    Correct

    Incorrect

  17. Question 17 of 20
    17. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int fun(int t[]) {
            t[0] += t[1];
            return t[0];
        }
        
        int main() {
            int t[] = { 5,6,7 };
            cout << fun(t);
            cout << t[0];
            return 0;
        }

    Correct

    Incorrect

  18. Question 18 of 20
    18. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int *make(int v) {
            int *p = new int;
            *p = v + 1;
            return p;
        }
        int *play(int &v) {
            cout << ++v;
            return &v;
        }
        
        void remove(int *v) {
            delete v;
        }
        
        int main() {
            remove(play(*make(3)));
            return 0;
        }

    Correct

    Incorrect

  19. Question 19 of 20
    19. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        int main() {
            int *val = new int;
            *val = sizeof(val) / sizeof(int *);
            int *tab = new int[*val];
            tab[0] = *val;
            delete val;
            cout << *tab;
            delete [] tab;
            return 0;
        }

    Correct

    Incorrect

  20. Question 20 of 20
    20. Question
    1 points

    What is the output of the following program?

     

        #include <iostream>
        using namespace std;
        
        struct s {
            float *f;
        };
        
        void make(s *p, float x = 10) {
            float *f = new float;
            *f = sizeof(*f) / sizeof(float) * 10;
            p->f = f;
        }
        
        int main() {
            s *ss = new s;
            make(ss);
            cout << *(*ss).f;
            delete ss->f;
            delete ss;
            return 0;
        }

    Correct

    Incorrect

  • CCNA1 v7
  • CCNA2 v7
  • CCNA3 v7
System Test Exam Answers
Modules 1 – 3 Exam Answers
Modules 4 – 7 Exam Answers
Modules 8 – 10 Exam Answers
Modules 11 – 13 Exam Answers
Modules 14 – 15 Exam Answers
Modules 16 – 17 Exam Answers
Practice Final – ITN Answers
Course Feedback
ITN Practice PT Skills Assessment (PTSA)
Final Exam Answers
Modules 1 – 4 Exam Answers
Modules 5 – 6 Exam Answers
Modules 7 – 9 Exam Answers
Modules 10 – 13 Exam Answers
Modules 14 – 16 Exam Answers
ITN Practice Skills Assessment – PT Answers
SRWE Practice Skills Assessment – PT Part 1 Answers
SRWE Practice Skills Assessment – PT Part 2 Answers
SRWE Hands On Skills Exam Answers
SRWE Practice Final Exam Answers
SRWE Final Exam Answers 
Modules 1 – 2 Exam Answers
Modules 3 – 5 Exam Answers
Modules 6 – 8 Exam Answers
Modules 9 – 12 Exam Answers
Modules 13 – 14 Exam Answers
ITN Practice PT Skills Assessment (PTSA) Answers
SRWE Practice PT Skills Assessment (PTSA) – Part 1 Answers
SRWE Practice PT Skills Assessment (PTSA) – Part 2 Answers
ENSA Practice PT Skills Assessment (PTSA) Answers
ENSA Hands On Skills Exam Answers
Practice Final – ENSA Answers
ENSA Final Exam Answers
CCNA Certification Practice Exam Answers

Copyright © 2023 PressExam.