I have a problem that I can not solve and it is because I mark the word of
error when I'm creating a list. I have the class imported
List<Integer> numeros = List.of(1,2,3,4);
I have a problem that I can not solve and it is because I mark the word of
error when I'm creating a list. I have the class imported
List<Integer> numeros = List.of(1,2,3,4);
You can use this code that allows you to do what you need.
List<Integer> numeros = Arrays.asList(1,2,3,4,5);