Comment on Tutorial - Method Overriding in Java By Henry



Comment Added by : SUNIL SHAH

Comment Added at : 2012-05-25 06:17:23

Comment on Tutorial : Method Overriding in Java By Henry
you have extended class Abc within class Abc
the correct code is
class Abc
{
public void display()
{
System.out.println("hai");
}
}
class Bca extends Abc
{
public void display()
{
System.out.println("hello");
}
public static void main(String[] args)
{
Bca obj=new Bca();
obj.display();
}
}


View Tutorial



Subscribe to Tutorials

Related Tutorials

Program using concept of byte long short and int in java

Update contents of a file within a jar file

Tomcat and httpd configured in port 8080 and 80

Java File

Java String

Count number of vowels, consonants and digits in a String in Java

Reverse a number in Java

Student marks calculation program in Java

Handling Fractions in Java

Calculate gross salary in Java

Calculate average sale of the week in Java

Vector in Java - Sample Program

MultiLevel Inheritance sample in Java

Multiple Inheritance sample in Java

Java program using Method Overriding

Archived Comments

1. its working... thanks.. thank you very much...!!!!
View Tutorial          By: Viswanathan at 2008-08-18 06:54:09

2. Thank you very much. This is the easiest and also
View Tutorial          By: Mehmet Üsküp at 2013-06-17 21:08:08

3. Dear any buddy i use Nokia N73 and connect with Bl
View Tutorial          By: zstranger at 2012-03-29 07:43:12

4. Hello,

Can you please send me the c

View Tutorial          By: criz at 2007-10-16 21:06:30

5. #!/bin/bash

echo "Enter number

View Tutorial          By: ashish at 2011-03-25 07:46:09

6. Gud one for beginners
View Tutorial          By: puneet at 2011-07-20 05:00:42

7. I am getting error like this:
javax.comm:

View Tutorial          By: Santhosh Samban at 2015-01-06 13:47:39

8. Nice post. Can you tell me how can i add shape in
View Tutorial          By: Sonia at 2012-06-08 04:57:18

9. Unable to understand all the points, quiet confusi
View Tutorial          By: KB at 2015-04-15 10:11:14

10. Sir , I am doing BCA . I want to know more about j
View Tutorial          By: sandeep Namdev at 2008-09-16 05:47:22