main()
{
int arr[5]={23,67};
printf("%d%d%d",arr[2],arr[3],arr[4]);
}

Answers were Sorted based on User's Feedback



main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / vikas upendra

The rest will be initialized to zero ....so it'll be 000 ..

Is This Answer Correct ?    25 Yes 4 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / jaga

in linux it will give garbage values...
in unix it will give 000(automatically initialized to 0)

Is This Answer Correct ?    11 Yes 2 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / vignesh1988i

all wil print the garbage values in the respected
memories... since we only initilized for two locations in
th array.... so other locations in the array wil have
garbage values

Is This Answer Correct ?    13 Yes 9 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / bsn.teja

till array elements are not given any specific values,they
are supposed to contain garbage values.
here we initialised only 1st two elements of the array.
so output will be garbage values.

Is This Answer Correct ?    2 Yes 0 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / kantilal

000

Is This Answer Correct ?    5 Yes 4 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / guruprasad

first a[0]=23;
a[1]=67;
rest index are assigned 0 0 0.

Is This Answer Correct ?    1 Yes 0 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / ismail

garbage value

Is This Answer Correct ?    5 Yes 5 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / abhisheksingh462

000

Is This Answer Correct ?    0 Yes 0 No

main() { int arr[5]={23,67}; printf("%d%d%d",arr[2],arr[3],arr[4]); }..

Answer / honey

000 PRINTED

Is This Answer Correct ?    1 Yes 3 No

Post New Answer

More C Interview Questions

any function have arguments one or more OR not . it is compulsary a) any function compulsary have one or more arguments b) any function did not have arguments. It is not compulsary c) it is optional it is not compulsary d) none of the above

0 Answers  


In a header file whether functions are declared or defined?

0 Answers   TISL,


int a=1,b=2,c=3; printf("%d,%d",a,b,c); What is the output?

14 Answers   Verifone,


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.

0 Answers  


Why is c called "mother" language?

0 Answers  


name the language for writing c compiler?

3 Answers   Microsoft,


7-Given an index k, return the kth row of the Pascal's triangle. For example, when k = 3, the row is [1,3,3,1]. For reference look at the following standard pascal’s triangle.

0 Answers  


Which of the following operators is incorrect and why? ( >=, <=, <>, ==)

0 Answers  


Can we compile a program without main() function?

0 Answers  


Can you please explain the difference between syntax vs logical error?

0 Answers  


main() { int x=10,y=15; x=x++; y=++y; printf("%d %d\n",x,y); } output??

19 Answers   EBS, Ramco, Sangwin, TCS,


What does the error message "DGROUP exceeds 64K" mean?

0 Answers   Celstream,


Categories