Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

how many ways to create Thread and which one is good?
runnable interface ot Thread class?

Answer Posted / srinu

Two ways of creating Thread
1)By extending java.lang.Thread class
2)By implementing java.lang.Runnable interface
Here 2"nd way is good because by using interface we can
implement multiple inheritance in our class

Is This Answer Correct ?    7 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is string and its types?

1187


What is collection class in java? List down its methods and interfaces.

968


Why is it called boolean?

1005


How do I start learning java?

1071


What is a string token?

1049


What is java in simple terms?

1000


Howto get an object that will perform date & time calculations then format it for output in some different locales with different date style.can ne1 tel me the answer of this question.pls

1921


What is polymorphism java example?

1019


Discuss 2D arrays.

1051


What is general methodology?

1038


How would you use Bubble Sort to sort the number of elements?

1006


What is methodological theory?

996


What are the drawbacks for singleton class?

1023


How do you use wildcards?

1063


How do you use nextline in java?

977