C Programming - Pointers - Discussion

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

MN SWARNA said:   1 decade ago
The 'void' keyword is represent no value but null pointer \0 or 0.

So () denotes the value * denotes address of memory location,

so (void*)0 is represent the NULL POINTER.

Dileep Gidwani said:   1 decade ago
As we know pointer doesn't have any return type, we write the keywords like int, float or char before * when we create a pointer. These keyword show that which type of value's or variable's address pointer will keep. And here we can see that we have used void before * that means pointer will not point any memory location. And we know that pointer which doesn't point any memory location is called null pointer.

Priti Dhingra said:   1 decade ago
It is null pointer which is indicating a memory having nothing in it or void memory. But as it is pointer, it will store the address.

Dinesh said:   1 decade ago
It refers null pointer. Because the return type void is mentioning the null (nothing). So it can be refered like this.

Prashant said:   1 decade ago
How we can use void pointer?

Abhay said:   1 decade ago
Pointers is I think the toughest topic I had ever came across about c. Can anybody please give some basics of pointer in simple language.

Sachin said:   1 decade ago
I think answer should be B, as void * shows that it is pointer to a data type, means it is a pointer to void data type, it will store the address of any data type.

Jiten said:   1 decade ago
I think void is the correct answer because void means no return type, but we know pointer should indicates address of the data type, but no return datatype are here. So (void*) indicates the NULL pointer.

Bandita said:   1 decade ago
Thnaks Nikhilesh.

Srr said:   1 decade ago
Void means no return type and * means finding the address of return type. So that is represented as null pointer.


Post your comments here:

Your comments will be displayed after verification.