Does Java have a “IN” operator or function like SQL? [duplicate]

There are many collections that will let you do something similar to that. For example:

With Strings:

String s = "I can has cheezeburger?";
boolean hasCheese = s.contains("cheeze");

or with Collections:

List<String> listOfStrings = new ArrayList<String>();
boolean hasString = listOfStrings.contains(something);

However, there is no similar construct for a simple String[].

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)