Guest User

Untitled

a guest
Jan 16th, 2018
99
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.30 KB | None | 0 0
  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. });
Add Comment
Please, Sign In to add comment