What is a task's priority and how is it used in scheduling?
A scheduler uses the priorities of a task to determine its execution. Priorities can be high or low determined by the integer values that are assigned to the tasks.
Example: JVM selects to run a Runnable thread with the highest priority.
All Java threads have a priority in the range 1-10.
Top priority is 10, lowest priority is 1.Normal
priority ie. priority by default is 5.