8
In C# there is the method contains
of System.Linq that searches text in a list, I did the tests in Java and I did not find a similar way even knowing that in Java 8 has expression, there is some way to do this with expression in Java?
Example:
ArrayList<String> strListas = new ArrayList<>();
strListas.add("Paulo");
strListas.add("Adriano");
strListas.add("Paula");
strListas.Contains("Pa");
Upshot:
Paulo e Paula
I believe this is possible only with loop.
– user28595
@diegofm has an example to give, please thank you!
– Paula Martins