wats the diference btwen constant pointer and pointer to a
constant.pls give examples.
Answer Posted / sanjay
Pointer to a consttant ::: such that the value to which
pointer points can't be changed
const int *ptr1=7
*ptr=8 // invalid
constant pointer :::: pointer direction can't be cheged .
int *const x =6;
x=7 or x=&i // invalid
Location of pointer can't be chenged.
| Is This Answer Correct ? | 18 Yes | 2 No |
Post New Answer View All Answers
Find the second largest element in an array with minimum no of comparisons and give the minimum no of comparisons needed on an array of size N to do the same.
What is a dynamic array in c?
Why do some versions of toupper act strangely if given an upper-case letter?
How many bytes are occupied by near, far and huge pointers (dos)?
What is a newline escape sequence?
Explain what are linked list?
What is the meaning of typedef struct in c?
How many levels deep can include files be nested?
Does c have class?
A float occupies 4 bytes in memory. How many bits are used to store exponent part? since we can have up to 38 number for exponent so 2 ki power 6 6, 6 bits will be used. If 6 bits are used why do not we have up to 64 numbers in exponent?
What are terms in math?
How can I read and write comma-delimited text?
List the difference between a While & Do While loops?
What is the difference between malloc calloc and realloc in c?
What are the uses of null pointers?