So I have this code, where en1 is an instance of a object.
for (int i = 0; i < 20; i++) {
System.out.println("Introduce el nombre de una empresa");
Scanner scanner = new Scanner(System.in);
en1.setName(scanner.next());
}
I would like to change the 1 on en1 to the loop counter. Is this possible?