title: Accessing pointer member data of struct
body: <p>I am trying to access the data of a pointer that is a member of a struct.</p>
  
  <pre><code>typedef struct
  {
      int i1;
      int* pi1;
  } S;
  
  
  int main()
  {
      S s1 = { 5 , &amp;(s1.i1) };
  
      printf("%u\n%u\n" , s1.i1 , s1.pi1 ); //here is the problem 
  
  return 0;
  }
  </code></pre>
  
  <p>The problem lies in the second argument of printf. When i run the program i get the following result in console:  5 ...(next line) 2381238723(it's different every time).
  This is correct, and the result is not unexpected. I have tried things like:</p>
  
  <pre><code>*(s1.pi1) 
  </code></pre>
  
  <p>and</p>
  
  <pre><code>s1.*pi1
  </code></pre>
  
  <p>None of them works. Is there any operator in C or method to do this?</p>