java tutorial - What if we call run() method directly - java programming - learn java - java basics - java for beginners
Learn Java - Java tutorial - What if we call run method directly - Java examples - Java programs
What is the run method?
- The method is a set of code which referred to by name and it can be called (invoked) at any point in a program just by utilizing the method's name.
- Think of a method as a subprogram that acts on data and often returns a value. Each method has its own name.
What if we call run() method directly instead start() method?
- To invok run() method on or after the main thread, then the method go onto the present call stack sooner than at the starting of a new call stack.