remove element using java