C Programming - Typedef - Discussion

Discussion Forum : Typedef - Yes / No Questions (Q.No. 1)
1.
Is the following declaration acceptable?
typedef long no, *ptrtono;
no n;
ptrtono p;
Yes
NO
Answer: Option
Explanation:
No answer description is available. Let's discuss.
Discussion:
14 comments Page 2 of 2.

Suraj Mundalik said:   8 years ago
It will be like this;

long n;
long *p;

Yash said:   8 years ago
Yes, right @Sanju.

Siddhartha soam said:   5 years ago
Here, ptrtono is declared as a pointer
but in third line(ptrtono p;) is wrong because, we have to use & operator to store a pointer value.

So the correct form is(ptrtono &p;).

Correct me if I am wrong.

Ashok said:   4 years ago
If anyone knows what is the typedef? Please anyone explain me.
(1)


Post your comments here:

Your comments will be displayed after verification.