Java
Programming and Technical
Programming
Technical
Q. Explain different way of using thread?
A. A Java thread could be implemented by using Runnable interface or by extending the Thread class. The Runnable is more advantageous, when you are going for multiple inheritance.
Read Solution (Total 3)
-
- there are two ways
1.extend thread class or
2.implement runnable interface - 11 years agoHelpfull: Yes(0) No(0)
- there are 2 ways of using thraeds.
first one is extending the Thread class
and other is implementing the Runnable Interface - 10 years agoHelpfull: Yes(0) No(0)
- normally there are two ways
1.extend thread class or
2.implement runnable interface
but one more way to using anonymous - 10 years agoHelpfull: Yes(0) No(0)
Java Other Question