GATE CS 2017 (Afternoon) — Question 55

Programming in CPointers, Multi-Dimensional Arrays, StructuresNAT2 marksHard

Consider the following C program.
c
1# include <stdio.h>
2# include <string.h>
3int main( )
4{
5    char* c = "GATECSIT2017";
6    char* p = c;
7    printf("%d", (int) strlen (c+2[p] - 6[p]-1));
8    return 0;
9}
10
The output of the program is ________.
Practise the full 2017-AN paper
Challenge a friend: WhatsApp Telegram
From RENYXERAPractise this subject in the exam simulatorTimed, GATE-style tests with analytics that find your weak topics.
Practise more on Pointers, Multi-Dimensional Arrays, StructuresTimed, in the real exam interface · free to start

A GATE question every morning

One real past-paper question every morning for your branch, answer hidden until you tap. Free on Telegram.

Join
Stuck? Ask in the student group