Posted by: paani_ma_paade_jasto July 12, 2015
little help for java newbie please!!
Login in to Rate this Post:     0       ?        
You can not just remove any element from array in java . The closest thing you can do is put some recognizable value there in that index like like 999 etc . Or you can use list if that is permissible. if you just want to drop third student and add sixth student, you can just add/put that sixth student in the index of third student, which will replace the third student.
Your dropStudent does not look good. You are passing student object, so you will need to loop through the array, find the index of that student in that array and then act on that index, probably set null so that you can identify it later.
Read Full Discussion Thread for this article