ExitPrep

Home / Exit exam / Past papers / Model Exit Exam 2017 E.C. - Round 3 (CSE)

Model Exit Exam 2017 E.C. - Round 3 (CSE): questions and answers

Model exam for Computer Science & Engineering, Computer Science, 2017 E.C. (2025 G.C.). 100 questions, 120 minutes. A model exam written to match the format and difficulty of the real paper, with explanations.

100questions
120minutes
Premiumfull paper

The first 5 questions

Open "Show answer" under a question to see the correct option and the explanation. The full paper, with the clock, scoring and a review of every question, is in the app.

1. Which of the following will correctly declare a constant symbolic value for PI in C++?

  1. #define PI = 3.14
  2. const float PI = 3.14;
  3. constant PI = 3.14;
  4. final float PI = 3.14;
Show answer

Answer: B. const float PI = 3.14;

2. What will be the output of the following code? int arr[] = {10, 20, 30, 40, 50}; int *ptr = arr + 2; cout << *ptr << " " << *(ptr + 1);

  1. 20 30
  2. 10 20
  3. 30 40
  4. 40 50
Show answer

Answer: C. 30 40

3. Which of the following correctly dynamically allocates memory for an array of 10 integers in C++?

  1. int arr[10] = new int;
  2. int *arr = new int[10];
  3. int *arr = malloc(10 * sizeof(int));
  4. int arr = new int[10];
Show answer

Answer: B. int *arr = new int[10];

4. What is the main difference between passing an array to a function by value vs. by pointer?

  1. Arrays can only be passed by pointer, not by value
  2. Passing by value creates a copy; passing by pointer does not
  3. There is no difference in C++
  4. Passing by pointer is slower than passing by value
Show answer

Answer: A. Arrays can only be passed by pointer, not by value

5. Which mode should be used to open a file for both reading and writing in C++?

  1. ios::in
  2. ios::out
  3. ios::in | ios::out
  4. ios::app
Show answer

Answer: C. ios::in | ios::out

95 more questions in this paper. This paper is part of Premium, from 200 ETB for 3 months, together with every other paper, all chapters and unlimited practice.

Take the full Computer Science paper

Start free with the oldest paper of your department, then unlock this one with Premium.

Start studying free Log in

All Computer Science papers, notes and practice