Hi Friends, can you give difference between extending thread
class and implementing runnable interface.
Answer Posted / murali.25
both will achieve the same functionality. Usually we implement runnable interface because if we extend thread and if we want to any application specific class, its not possible because java doesnt support multiple inheritance.
Is This Answer Correct ? | 1 Yes | 0 No |
Post New Answer View All Answers
What is a void in java?
Differentiate between a class and an object.
How to solve the problem of generating the unique hash keys with hash function?
Is string is a data type?
What is javac used for?
Why we use protected in java?
Which variables are stored in heap?
What is the difference between the paint() and repaint() methods?
What are the object and class classes used for?
What classes of exceptions may be caught by a catch clause in java programming?
Tell me the latest versions in java related areas?
What is linked hashset and its features?
why Java does not support multiple inheritances?
What is the difference between assignment and initialization?
Why is multiple inheritance not supported in java?