The processor of your computer should have something like 4 cores.
Those 4 different cores are able to work parallel.
So when you have a task that can be divided into smaller independent packages of work, it can be a huge advantage to make use of multiple cores of your processor.
In java it is quite easy to use multiple cores. All you need to do is creating a new Thread(that's how the individual parts of your program that are distributed on multiple cores are called.) and tell the new Thread what it should do. There are two ways you could do this. And both of them involve object orientation:
When counting your threads to keep up with the processor count of your computer you need to keep in mind that the main thread(the one that calls the static void main(…)
) is also a thread!
Also you should keep in mind that variables from one thread won't be passed to another thread immediately! So when you need to share data between the threads you need to be careful!
Congratulations @quantumdeveloper! You have completed the following achievement on the Steem blockchain and have been rewarded with new badge(s) :
You can view your badges on your Steem Board and compare to others on the Steem Ranking
If you no longer want to receive notifications, reply to this comment with the word
STOP
Downvoting a post can decrease pending rewards and make it less visible. Common reasons:
Submit