GateQA is a free GATE CS preparation platform featuring 3,500+ previous-year questions (1987–2026),
36,000+ aptitude questions, subject-wise and year-wise mock tests, performance analytics,
and full offline support. Practice Operating Systems, Algorithms, DBMS, Computer Networks,
Theory of Computation, Discrete Mathematics, Compiler Design, Digital Logic, and more.
Consider the C program given below : #include <stdio.h> int main { int sum = 0, maxsum = 0, i, n = 6; int a = {2, -2, -1, 3, 4, 2}; for (i = 0; i < n; i++) { if (i == 0 || a [i] <…
Answer: C
This static SEO snapshot loads the full interactive GateQA app when JavaScript is available.