MCPcopy Create free account
hub / github.com/PrajaktaSathe/Java / findAllWordsThatContainLetterA

Method findAllWordsThatContainLetterA

Programs/JavaStreams.java:25–29  ·  view source on GitHub ↗
(List<String> words)

Source from the content-addressed store, hash-verified

23
24 //Use stream to find all numbers that contain the letter a
25 public static List<String> findAllWordsThatContainLetterA(List<String> words){
26 return words.stream()
27 .filter(word -> word.contains("a"))
28 .collect(Collectors.toList());
29 }
30
31 //print out the origin lists, and then the changed lists
32 public static void main(String[] args) {

Callers 1

mainMethod · 0.95

Calls

no outgoing calls

Tested by

no test coverage detected