why Runnable interface is preferable than extending the
Thread class?

Answer Posted / rameshkrishna

imolimen Runnabule inerface and extends Thread functionally
both are same.But implimenting RunnebleInterface more
advantage because of there is possibility extends more then
one class and also we can override run() only once.

Is This Answer Correct ?    10 Yes 4 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can we create a thread in java?

591


What is the difference between post and put?

540


What is the purpose of the runtime class in java programming?

570


What is the purpose of the System class?

583


What does the exclamation mark mean in java?

598






What is your platform?s default character encoding and how to know this?

1755


What is the difference between size and length in java?

522


Discuss different types of errors that generally occur while programming.

583


Does java support multiple inheritances?

561


What is final variable?

503


What are voids?

539


What is array sorting in java?

557


What are data types in oop?

557


How would overload a function based on return type?

552


Is java a prime method?

555