Pointer to a structure within a structure

Hi everyone, I am unsure on how the syntax works for pointing to a structure within a structure and cannot find anything to help me.
So if I have this structure:

1
2
3
4
5
6
7
struct a{
     struct b{
          int c;
          int d;
     } alphabet;
     int e;
} whatever;


I understand that a pointer to say, e would be like this:
1
2
3
a* p_a;
p_a = &whatever;
cout << p_a->e;


but how would I do a pointer to say c or d?

Many thanks,
Phill
Do you mean something like:

p_a->alphabet->c;?
In this case, it would be p_a->alphabet.c becuse alphabet is not a pointer type within the structure.
Topic archived. No new replies allowed.