Новый курс! Каждый программист должен знать генеративный ИИ!
Попробуйте бесплатный урок+ 1
When do we use Sets or Lists in Java?
sets or Lists java
1 ответ
+ 4
List can contain duplicate elements and Set can not. Also Set elements cannot be accessed by index. So your choice here depends of your task.