Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Aprenda Challenge: Factory Product Filtering | Intermediate Operations in Stream API
Stream API
course content

Conteúdo do Curso

Stream API

Stream API

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

book
Challenge: Factory Product Filtering

Tarefa

Swipe to start coding

The factory produces products represented by Product objects, which have the fields id, weight, and quality.

  1. Filter the products to keep only those with a quality of "GOOD" and a weight greater than 10.0.
  2. Extract only the id of the filtered products using a method reference.
  3. Once the result is collected into a list, print the id of the selected products using a method reference to println.

Solução

java

solution

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Seção 2. Capítulo 3
toggle bottom row

book
Challenge: Factory Product Filtering

Tarefa

Swipe to start coding

The factory produces products represented by Product objects, which have the fields id, weight, and quality.

  1. Filter the products to keep only those with a quality of "GOOD" and a weight greater than 10.0.
  2. Extract only the id of the filtered products using a method reference.
  3. Once the result is collected into a list, print the id of the selected products using a method reference to println.

Solução

java

solution

Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
Tudo estava claro?

Como podemos melhorá-lo?

Obrigado pelo seu feedback!

Seção 2. Capítulo 3
Switch to desktopMude para o desktop para praticar no mundo realContinue de onde você está usando uma das opções abaixo
We're sorry to hear that something went wrong. What happened?
some-alt