Question: A collection like ArrayList students could contain two or more references to the same object (same student enrolled in more than one course). Therefore, students.size()
A collection like ArrayList
int totalStudents;
Provide a single statement that assigns to totalStudents the total number of distinct Student objects in the students collection.
Step by Step Solution
3.52 Rating (152 Votes )
There are 3 Steps involved in it
Sure I can definitely help with that You can use a javautilSet to handle this as Set in Java does no... View full answer
Get step-by-step solutions from verified subject matter experts
