C Programming - Pointers - Discussion

Discussion Forum : Pointers - General Questions (Q.No. 1)
What is (void*)0?
Representation of NULL pointer
Representation of void pointer
None of above
Answer: Option
No answer description is available. Let's discuss.
122 comments Page 1 of 13.

Mayur 22kar said:   3 years ago
A void pointer is a pointer which nothing points anywhere In memory.

A null pointer means a pointer pointing to zero. In computer language, null value its just like initialize with zero.

Shubham patra said:   11 months ago
Because it is not pointing to any memory address therefore it's a null pointer.

And we also avoid parenthesis.

Swapnil Nimbalkar said:   1 year ago
Please explain it.

Hossam Ahmed ALi said:   7 months ago
I think the right answer is B) Void pointer.

The void pointer can point to any variable of any data type or point to NULL which means points to no location in the memory.

Vidhi said:   6 years ago
void *ptr indicate void or generic pointer.

So (void *) is the address of pointer ptr.

Gerry said:   6 years ago
Very informative. Thanks.

Paste said:   1 decade ago
Please explain.

Abhishek Anand said:   1 decade ago
Can Anybody, explain this Please

JEHO said:   1 decade ago
Void is used in 2 places.

1st void function_name (void).
1st void indicate functio type is null.

Eg int main, char main.

2nd (void) indicate no parameters in function.

3rd function of void is NULL POINTER.


Sree said:   1 decade ago
The void data type has no values.


int a=10; //right
void b=20;//wrong

a[address of 10]--------->10

b[address]---------> NULL (no value,no address so null)

So void is a representation of NULL.

Note: void *b; //right (no value, but we can store address)

Post your comments here:

Your comments will be displayed after verification.