title: How to create a directory in C++
body: <p>i just found a little piece of code that let me create a directory with windows API without using system(). The only problem is that i can't create directory in subdirectory.
  For example </p>
  
  <pre><code>#include&lt;windows.h&gt;
  
  int main(){
     CreateDirectory ("C:\\random", NULL);
     return 0;
  }
  </code></pre>
  
  <p>Create a folder named random in C.</p>
  
  <p>But if i do</p>
  
  <pre><code>#include&lt;windows.h&gt;
  
  int main(){
     CreateDirectory ("C:\\Users\morons", NULL);
     return 0;
  }
  </code></pre>
  
  <p>It creates in C che folder named Usersmorons and not the folder morons under Users.
  Any suggest?</p>