. Consider the following program
main()
{
int a[5]={1,3,6,7,0};
int *b;
b=&a[2];
}
The value of b[-1] is
(A) 1 (B) 3 (C) -6 (D) none

Answer Posted / harichandana

a[2] value is assigned to b i.e a[2] element value 6 is stored in b[0].now b[-1] means element before 6 i.e 3....thus b[-1] is 3

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a nested loop?

643


What are identifiers and keywords in c?

564


How do you print only part of a string?

609


What is a double c?

586


Why do we use c for the speed of light?

603






Which one would you prefer - a macro or a function?

598


What is string constants?

657


What is the size of enum in c?

614


Is it fine to write void main () or main () in c?

543


What is scope rule in c?

603


What are the c keywords?

747


What is a MAC Address?

624


Is it possible to initialize a variable at the time it was declared?

755


C program to find all possible outcomes of a dice?

1851


Are the variables argc and argv are local to main?

783