Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVA

check if list includes value java

The contains() method can be used to check if 
a Java ArrayList contains a given item or not

if (lista.contains(conta1)) {
    System.out.println("Account found");
} else {
    System.out.println("Account not found");
}
 
PREVIOUS NEXT
Tagged: #check #list #includes #java
ADD COMMENT
Topic
Name
4+6 =