Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Вивчайте Challenge: Filtering Users by Two Criteria | Fundamentals and Functional Capabilities of Stream API
Stream API
course content

Зміст курсу

Stream API

Stream API

1. Fundamentals and Functional Capabilities of Stream API
4. Practical Applications of Stream API

book
Challenge: Filtering Users by Two Criteria

Завдання

Swipe to start coding

Filter the users who are over 18 years old and have an "Active" status, then print them to the screen.

  1. Create a BiPredicate to check if age is greater than 18 and status is "Active".
  2. Inside forEach(), use the if statement to evaluate the user based on the BiPredicate.
  3. If the user satisfies the condition, print the user to the console.

Рішення

java

solution

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 1. Розділ 14
toggle bottom row

book
Challenge: Filtering Users by Two Criteria

Завдання

Swipe to start coding

Filter the users who are over 18 years old and have an "Active" status, then print them to the screen.

  1. Create a BiPredicate to check if age is greater than 18 and status is "Active".
  2. Inside forEach(), use the if statement to evaluate the user based on the BiPredicate.
  3. If the user satisfies the condition, print the user to the console.

Рішення

java

solution

Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
Все було зрозуміло?

Як ми можемо покращити це?

Дякуємо за ваш відгук!

Секція 1. Розділ 14
Switch to desktopПерейдіть на комп'ютер для реальної практикиПродовжуйте з того місця, де ви зупинились, використовуючи один з наведених нижче варіантів
We're sorry to hear that something went wrong. What happened?
some-alt