0
Here's an example: public void method(int x){ x = 5; } Overriden: public void method(int x){ x = 90; // when you override a method, you write the same method but with different code inside it. In the first method we assign x = 5, in the Overriden method we assign x = 90...different code } Overloaded: public void method(int x, int y){ //we only change the number of parameters of the method //typical overloaded methods would be constructors for example } Greetings :D
8th Jan 2018, 3:39 AM
jaaxdev
jaaxdev - avatar