Posts by Breno Teixeira Trancoso • 53 points
3 posts
-
1
votes3
answers4417
viewsA: Java 8 (Stream) - Grouped sum
I managed to solve the problem. Still, thanks for your help. How was the function: public static List<Object[]> calcularTotal(List<Object[]> lista, int chave, int... valores){…
-
2
votes3
answers4417
viewsQ: Java 8 (Stream) - Grouped sum
Good morning. I have the following function below: private List<Object[]> calcularTotal(List<Object[]> lista, int chave, int valor){ return lista.stream() .map(l -> new Object[]…
-
2
votes1
answer2885
viewsQ: Java 8 - Collecting elements from a list
Good morning. I would like to collect specific elements from a list. I could do the Java 7 style, but I’m curious to know how I would do in the Java 8 style. For example: [[1, 2, 3], [1, 2, 3], [4,…