What is the difference between set and list?

Answer Posted / krishnareddym. a

When we required uniqueness then we can use set and set
does not allow any duplications but list may contain
duplications set and list both extends collection interface...

Is This Answer Correct ?    22 Yes 6 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Write a program to find the whether a number is an Armstrong number or not?

567


Explain, java is compatible with all servers but not all browsers?

598


How to Sort Strings which are given in List and display in ascending order without using java api.

3748


State some advantages of java?

703


What are the benefits of immutable objects?

528






Why stringbuilder is not thread safe in java?

555


How many types of literals are there in JAVA?

582


What does ide stand for?

509


Can list have duplicates in java?

515


Why local variables are stored in stack?

486


Can an unreferenced object be referenced again?

750


What is boolean query?

521


What is skeleton and stub?

582


How to read and write image from a file ?

547


If I don't provide any arguments on the command line, then what will the value stored in the string array passed into the main() method, empty or null?

694