Hi Friends, can you give difference between extending thread
class and implementing runnable interface.
Answer Posted / ravikiran
By extending a thread class we will be restricted to the
implementation for single class only,by implementing
Runnable interface we will get extended for implementing
more than one thread
| Is This Answer Correct ? | 3 Yes | 1 No |
Post New Answer View All Answers
What is string buffer?
What is double checked locking in singleton?
What is toarray method in java?
How do you stop a thread in java?
What is difference between an object and a class?
1.IN CASE OF DYNAMIC METHOD DISPATCH WHY WE USE REFERENCE VARIABLE,WE CAN USE THE DIFFERENT DEFINED OBJECT DIRECTLY TO ACCESS THE DATA MEMBER AND MEMBER FUNCTION OF THAT RESPECTIVE CLASS?WHAT IS THE MAIN FUNCTION OF "REFERENCE VARIABLE" HERE?
What are the four pillars of java?
What is a ?
What do you understand by the term polymorphism?
What does escaping a character mean?
How can you set an applet’s height and width as a percentage?
Explain notify() method of object class ?
Explain polymorphism citing an example.
What is assembly used for?
Enlist diffrent types of inheritance supported by java?