title: how to declare inputs on one line in java
body: <p>I'm having trouble making my program read in all of the integers on one line rather than having to enter each number and hit enter after each digit in the terminal window.</p>
  
  <p>For example, the terminal window would read:</p>
  
  <pre><code>For the our text enter the first 9 digits: 013292373"
  </code></pre>
  
  <p>rather than</p>
  
  <pre><code>For the our text enter the first 9 digits: 0
  1
  2
  3
  ... etc"
  </code></pre>
  
  <p>My code looks like this so far:</p>
  
  <pre><code>/**
  * This program calculates the last number of a 10 digit ISBN number.
  */  
  import java.util.Scanner;
  public class ISBNnum
  {
  public static void main(String[] args)
  {
     //Variables and Scanner
     Scanner input = new Scanner(System.in);
     int dOne;
     int dTwo;
     int dThree;
     int dFour;
     int dFive;
     int dSix;
     int dSeven;
     int dEight;
     int dNine;
     int checksum;
  
     //Input
     System.out.print("For the our text enter the first 9 digits: ");
     dOne = input.nextInt();
     dTwo = input.nextInt();
     dThree = input.nextInt();
     dFour = input.nextInt();
     dFive = input.nextInt();
     dSix = input.nextInt();
     dSeven = input.nextInt();
     dEight = input.nextInt();
     dNine = input.nextInt();
  
     //Calculation
     checksum = ((dOne * 1) + (dTwo * 2) + (dThree * 3) + (dFour * 4) + (dFive * 5) + (dSix * 6) +
     (dSeven * 7) + (dEight * 8) + (dNine * 9)) % 11;
  
     //Output
     if (checksum == 10)
     {
         System.out.print("The whole ISBN is "+dOne+dTwo+dThree+dFour+dFive+dSix+dSeven+dEight+
         dNine+"X");
      }
      else if (checksum &lt; 10)
      {
      System.out.println("The whole ISBN is " + dOne + dTwo + dThree + dFour + dFive + dSix +
      dSeven + dEight + dNine + " - " + checksum);
  }
  }
  }
  </code></pre>
  
  <p>Thanks for your help guys!</p>