Why & is used in scanf in c?



Why & is used in scanf in c?..

Answer / Awadh Kishore

The ampersand (&) is used in the scanf function to pass a variable's address as an argument. This allows scanf to modify the actual value of the variable.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Interview Questions

What is structure packing ?

2 Answers   HP,


What is actual argument?

1 Answers  


write a program to find the number of even integers and odd integers in a given array in c language

13 Answers   IAI Cameroun, NIIT, Olive Tech, QIS,


If 4 digits number is input through the keyboard, Write a program to calculate sum of its 1st & 4th digit.

12 Answers   Google,


Is there something we can do in C but not in C++? Declare variable names that are keywords in C++ but not C.

2 Answers   Infosys,


What is a string?

1 Answers  


a C prog to swap 2 no.s without using variables just an array?

5 Answers   TCS,


is it possible to create your own header files?

1 Answers  


What is the use of the sizeof operator?

2 Answers  


How do I access command-line arguments?

2 Answers   Bosch, Wipro,


please give code for this 1 2 4 7 11 16

11 Answers   Intel, Wipro,


In the following code segment what will be the result of the function, value of x , value of y { unsigned int x=-1; int y; y = ~0; if(x == y) printf("same"); else printf("not same"); } a) same, MAXINT, -1 b) not same, MAXINT, -MAXINT c) same , MAXUNIT, -1 d) same, MAXUNIT, MAXUNIT e) not same, MAXINT, MAXUNIT

1 Answers   IBM,


Categories