title: Alternate between fwrite and fprintf on same file
body: <p>Is it possible to alternate writing between binary and regular writes on the same file?</p>
  
  <p>Would i just need to keep opening and closing the file like so?</p>
  
  <pre><code>struct node x;
  FILE* fout;
  fout = fopen("output.bin", "wb");
  fwrite(&amp;x, sizeof(struct node), 1, fout);
  fclose(fout);
  fout = fopen("output.bin", "a");
  fprintf("&amp;d", x.data);
  </code></pre>