GATE CSE C Programming Practice Test – Array & Pointer | Set 1

Questions 91-95 of 100

Your score 0/100 0 answered
Correct 0 Incorrect 0 Unanswered 100 Accuracy 0%

Question 91

NAT · Numerical Answer 1 mark

What is the output of the following C program?

C
#include <stdio.h>
int main(void) {
    int arr[] = {6, 30, 30, 40};
    int *p = arr;
    printf("%d", *(p + 1) - *p);
    return 0;
}
Answers for question 91

Question 92

NAT · Numerical Answer 1 mark

What is the output of the following C program?

C
#include <stdio.h>
int main(void) {
    int arr[] = {7, 35, 30, 40};
    int *p = arr;
    printf("%d", *(p + 1) - *p);
    return 0;
}
Answers for question 92

Question 93

NAT · Numerical Answer 1 mark

What is the output of the following C program?

C
#include <stdio.h>
int main(void) {
    int arr[] = {8, 40, 30, 40};
    int *p = arr;
    printf("%d", *(p + 1) - *p);
    return 0;
}
Answers for question 93

Question 94

NAT · Numerical Answer 1 mark

What is the output of the following C program?

C
#include <stdio.h>
int main(void) {
    int arr[] = {9, 45, 30, 40};
    int *p = arr;
    printf("%d", *(p + 1) - *p);
    return 0;
}
Answers for question 94

Question 95

NAT · Numerical Answer 1 mark

What is the output of the following C program?

C
#include <stdio.h>
int main(void) {
    int arr[] = {10, 50, 30, 40};
    int *p = arr;
    printf("%d", *(p + 1) - *p);
    return 0;
}
Answers for question 95
Scroll to Top