why Runnable interface is preferable than extending the
Thread class?
Answer Posted / srinu
you know that java does not supporting multiple inheritance
through classes .if u extend Thread class,u can't extend any
class which you required other than thread class.if u are
implementing runnable interface u can extend any class which
you required other than thread class.this is main advantage of
implementing java.lang.Runnable interface.
| Is This Answer Correct ? | 6 Yes | 3 No |
Post New Answer View All Answers
Can java program run without jre?
Can we cast any other type to boolean type with type casting?
Why vector class is used?
Is arraylist dynamic in java?
Is singleton class immutable?
What is java lang string?
Can a constructor call another constructor?
What does += mean coding?
What state is a thread in when it is executing?
Explain how to force the garbage collection in java.
What is generic class?
What is meant by anonymous class?
What is the default size of set in java?
What are different types of states exist for a thread?
If an object is garbage collected, can it become reachable again?