title: How to create a new text file in C?
body: <p>I am creating a program which reads data from one text file and changes it size to upper or lower case and then stores that data in a new file. I have searched the internet, but I can't find how to create a new text file. </p>
  
  <pre><code>#include &lt;stdio.h&gt;
  int main(void) {
  
          FILE *fp = NULL;
  
          fp = fopen("textFile.txt" ,"a");
  
          char choice;
  
          if (fp != NULL) {
  
                  printf("Change Case \n");
                  printf("============\n");
                  printf("Case (U for upper, L for lower) : ");
                  scanf(" %c", &amp;choice);
                  printf("Name of the original file : textFile.txt \n");
                  printf("Name of the updated file : newFile.txt \n");
  </code></pre>
  
  <p>I know this is incomplete, but I can't figure out how to crate a new text file!</p>