A class implementing an interface has to define all methods in an interface.
ArrayList implements List interface. List interface has 25 abstract methods. When I checked ArrayList class , it has 20 methods. Some of which may be completely new for this class. So, does this ArrayList class only contain all methods in List interface or only methods that have some code in them ?
Sai Roy, please go here, where you will read this:-
We're all here to learn, so when responding to others, please focus on helping them discover their own solutions, instead of simply providing answers.
By providing a complete answer you are depriving nirjari patel of the opportunity to learn how to find such information for oneself.
Please don't be annoyed, but I have pulled rank and deleted the solution and explanation, NP will actually have a chance to learn how to navigate the API documentation.