1 개요[ | ]
- 자바 HashMap .containsKey()
Java
Copy
import java.util.HashMap;
public class MyClass {
public static void main(String[] args) {
HashMap<String,Object> hm = new HashMap<String,Object>();
hm.put("first", "1");
hm.put("second", "4");
System.out.println( hm.containsKey("first") ); // true
System.out.println( hm.containsKey("third") ); // false
}
}
Loading
2 같이 보기[ | ]
3 참고[ | ]
편집자 Jmnote Jmnote bot
로그인하시면 댓글을 쓸 수 있습니다.