Scanner scan = new Scanner(System.in);
    String in;
    int count = scan.nextInt();
    for (int i = 0; i < count; i++){
        System.out.print("Input "+i+" of "+count+": ");
        in = scan.nextLine();
    }
As the title says, this for loop prints the line twice (with the "i" variable incremented once) before it stops to wait for user input. I don't understand why it does that. I tried to use while loop, with similar results. Help?
 
     
    