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

In this problem you are to write a program that will cut some number of prime numbers from the list of prime numbers between 1 and N.Your program will read in a number N; determine the list of prime numbers between 1 and N; and print the C*2 prime numbers from the center of the list if there are an even number of prime numbers or (C*2)-1 prime numbers from the center of the list if there are an odd number of prime numbers in the list.

1 Answers  


What is the purpose of main() function?

1 Answers  


What is null pointer in c?

1 Answers  


Program to find the sum of digits of a given number until the sum becomes a single digit. (e.g. 12345=>1+2+3+4+5=15=>1+5=6)

1 Answers   InterGraph,


How can I do graphics in c?

1 Answers  


Under what circumstances does a name clash occur?

1 Answers   InterGraph,


Where is c used?

1 Answers  


What is data structure in c language?

1 Answers  


the operator for exponencation is a.** b.^ c.% d.not available

5 Answers   TCS,


What does == mean in texting?

1 Answers  


being a chemical engineer and with an aggregate of 80% why you opt for TCS and not your core industry?

1 Answers   TCS,


Hi, main() { } Is a user defined function or Built in Functionn

26 Answers   Honeywell, Yahoo,


Categories