I need to accept user input immediately upon running my program : <p>First of all, I'm extremely new to Java, so simple answers would be much appreciated.
I'm trying to write a program so that the user can either input the following:</p>

<p>java howManyFiles 10</p>

<p>and get the output:</p>

<p>You selected 10 files.</p>

<p>Or, the user can input the following:</p>

<p>java howManyFiles</p>

<p>and get the output:</p>

<p>How many files would you like?</p>

<p>I can't seem to figure out a way to create a scanner that reads the initial input. The nextLine() scanner method looks for a new user input, rather than checking to see if one already exists. Any help would be a life saver. Thanks</p>
