hello everybody
can we change a the adress of a variabl i mean can i put for
exemple for a int *p:
&p=6
?????????
Answer / letskools
No,We cannot change the address of memory of a variable
because the addresses to the variable are provided by the
OS. We can only assign this address to the pointer variable
like this:
int x,*p;
P=&x;
We can change variable value through pointer like this:
*p=4;
but we can't change the variable address through the pointer
and also we can't provide any address to the pointer
variable directly as an "numeric constant" so this statement
is incorrect:
&p=6;
| Is This Answer Correct ? | 6 Yes | 0 No |
while loop contains parts a) initialisation, evalution of an expression,increment /decrement b) initialisation, increment/decrement c) condition evalution d) none of the above
What is pointers in c with example?
what is the difference between normal variables and pointer variables..............
15 Answers HP, Infosys, Satyam, Vivekanand Education Society,
What are preprocessor directives?
How do you determine a file’s attributes?
What is the difference b/w Structure & Class?
What is the difference between null pointer and wild pointer?
write a program to find the given number is prime or not
3 Answers Accenture, Vasutech,
what is default constructor?
cavium networks written test pattern ..
How to removing white spces in c programming only bu using loops
What is the equivalent code of the following statement in WHILE LOOP format?