what is the difference between : func (int list[], ...) or
func (int *list , ....) - what is the difference if list is an array and if also if list is a pointer

Answers were Sorted based on User's Feedback



what is the difference between : func (int list[], ...) or func (int *list , ....) - what is the ..

Answer / vimal

Nothing,because ultimately pointer to the first element of
array is send to the function,therefore using both method
changes made in called function will affect the calling
function. In one first you indirectly reference the pointer
and in other you directly reference the pointer.

Is This Answer Correct ?    2 Yes 0 No

what is the difference between : func (int list[], ...) or func (int *list , ....) - what is the ..

Answer / guest

in func(int list[]: it gives only the address of the value
which was stored in the list.
func (int *list , ....):it gives the value which is stored
in the list

Is This Answer Correct ?    0 Yes 3 No

Post New Answer

More C Interview Questions

What is int main () in c?

0 Answers  


how to print value of e(exp1)up to required no of digits after decimal?

1 Answers  


How can I split up a string into whitespace-separated fields?

0 Answers  


Device an algorithm for weiler-atherton polygon clipping, where the clipping window can be any specified polygon

0 Answers  


c programs are converted into machine language with the help of a) an interpreter b) a compiler c) an operatinf system d) none of the above

0 Answers  


number of times a digit is present in a number

0 Answers  


without using control structures and control structures find the max and min of given 2 nos

1 Answers   HCL,


write a own function for strstr

1 Answers   LG Soft,


what is data structure

5 Answers   Maveric, TCS,


what is unsigened char and what is the difference from char

2 Answers  


Is there any possibility to create customized header file with c programming language?

0 Answers  


Explain what does the format %10.2 mean when included in a printf statement?

0 Answers  


Categories