About Question enthuware.ocpjp.v7.2.1272 :
Moderator: admin
- 
				jagoneye
 - Posts: 97
 - Joined: Wed Dec 28, 2016 9:00 am
 - Contact:
 
About Question enthuware.ocpjp.v7.2.1272 :
Complicated example which could have been much simpler.  
			
			
									
									
						- 
				jagoneye
 - Posts: 97
 - Joined: Wed Dec 28, 2016 9:00 am
 - Contact:
 
Re: About Question enthuware.ocpjp.v7.2.1272 :
Code: Select all
int mid = (from+to)/2;
ComplicatedTask newtask1 = new ComplicatedTask(ia, from, mid); ComplicatedTask newtask2 = new ComplicatedTask(ia, mid+1, to); 
invokeAll(newtask1,newtask2);
sum = newtask1.join()+newtask2.join();
So does this code execute in multi-threads or perform computations locally only?
Who is online
Users browsing this forum: No registered users and 26 guests