Given a piece of code
int x[10];
int *ab;
ab=x;
To access the 6th element of the array which of the
following is incorrect?
(A) *(x+5) (B) x[5] (C) ab[5] (D) *(*ab+5} .

Answers were Sorted based on User's Feedback



Given a piece of code int x[10]; int *ab; ab=x; To access the 6th element of the array which o..

Answer / pradeep

answer: D(invalid indirection)

Is This Answer Correct ?    17 Yes 1 No

Given a piece of code int x[10]; int *ab; ab=x; To access the 6th element of the array which o..

Answer / sandzee

d

Is This Answer Correct ?    4 Yes 0 No

Post New Answer

More C Interview Questions

any C program contains only one function, it must be a) void () b) main () c) message () d) abc ()

0 Answers  


explain about storage of union elements.

2 Answers   ABC, Bosch,


program to find the second largest word in a paragraph amongst all words that repeat more thn twice

4 Answers   CTS, iGate,


Describe the difference between = and == symbols in c programming?

0 Answers  


What's a "sequence point"?

3 Answers  






What are different storage class specifiers in c?

0 Answers  


Define C in your own Language.

0 Answers   Motorola,


Why shouldn’t I start variable names with underscores?

0 Answers  


What is your favorite subject?

1 Answers   Ericsson, Invendis, Tech Mahindra,


What is dynamic dispatch in c++?

0 Answers  


What is page thrashing?

0 Answers  


What are header files and explain what are its uses in c programming?

0 Answers  


Categories