daily pastebin goal
8%
SHARE
TWEET

Untitled

a guest Jan 16th, 2018 62 Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
  1. employeeList.stream().collect(Collectors.groupingBy(person -> person.age))
  2.     .forEach((age, person) -> {
  3.       System.out.print("In the age " + age + " the following people are present ");
  4.       person.forEach(name -> System.out.print(name.getFirstName() + ", "));
  5.       System.out.println("");
  6.     });
RAW Paste Data
Top