how to check if an array contains an object java code example Example: check if object in array java Arrays.asList(yourArray).contains(yourValue)