Whenever we write a servlet, we inherit our class from HttpServlet which contains two service methods. Let’s have a look at the difference between both.
This article assumes that you have a basic knowledge of method overriding and overloading.
This is one of the mostly asked question in job interviews or other professional gatherings.
Most of the candidates are able to tell the difference but they get stuck in the second part, WHEN TO USE WHICH ?