Can you tell me what is wrong with the following code:
    Scanner input = new Scanner(System.in);
    Vector <Vector <String>> allValues = new Vector <Vector <String>>();
    Vector <String> currentTestValues = new Vector <String>();
    int tests = input.nextInt();
    for (int i = 0; i < tests; i++){
        int deposits = input.nextInt();
        for (int j = 0; j < deposits; j++){
            String s = input.nextLine();
            currentTestValues.add(s);
        }
        allValues.add(currentTestValues);
        currentTestValues.clear();
    }
    for (Vector <String> v : allValues){
        for (String s : v){
            System.out.println(s);
        }
    }
It seems to terminate after input.nextLine();
How to fix it?
 
     
    