java see if string is contained in other code example
Example 1: check if a string contains a character java
string.indexOf('a')
Example 2: string contains specific word in java
public boolean String.contains(CharSequence s);
string.indexOf('a')
public boolean String.contains(CharSequence s);