C++ Auto Format
<p>I am trying to create a program that auto formats my f:\ (USB Drive), and I have this code so far:</p>

<pre><code>#include &lt;stdio.h&gt;
#include &lt;stdlib.h&gt;
#include &lt;windows.h&gt;
#include &lt;iostream&gt;

int main ()
{
  system ("format f:");
  system("pause");
  return 0;
}
</code></pre>

<p>Now, when I run that, it comes up, with me needing to press <kbd>Y</kbd>, then <kbd>Enter</kbd>. How can I simulate that?</p>
