GATE Programming and Data Structures: Arrays – Previous Year Questions
7 GATE previous year questions on Arrays (Programming and Data Structures, Computer Science) with answers and explanations, from every paper.
7 questions worth 11 marks in all (3 1-mark, 4 2-mark). Asked between 2014 and 2021, so you can see how the topic has been tested over time.
- GATE 2021 CS (CS2) Q20 – What is printed by this source C program under its contiguous-array addressing model?
- GATE 2015 CS (CS3) Q50 – In C, Y has length n and X is n×n, 2≤n≤10. Initially Y is zero and X[i][j]=i+j; all of X lies in one memory page frame. Segment 1 loops i=0,…,n−1 with…
- GATE 2015 CS (CS2) Q48 – A Young tableau has unique finite entries increasing along rows and columns; empty cells are ∞, with no finite entry to the right of or below an empty…
- GATE 2014 CS (CS3) Q20 – A is an n × n square matrix. What does this pseudocode output? C = 100; for i = 1 to n do for j = 1 to n do Temp = A[i][j] + C; A[i][j] = A[j][i];…
- GATE 2014 CS (CS1) Q51 – Consider this C function, where size is the number of elements in E: int MyX(int *E, unsigned int size) int Y = 0, Z, i, j, k; for (i = 0; i < size;…
- GATE 2016 CS (CS1) Q44 – The following function computes the maximum value contained in an integer array `p[]` of size n (n 1). The missing loop condition is
- GATE 2019 CS Q34 – Consider the following C program: The number that will be displayed on execution of the program is .