问题描述:

I want to sort two arrays simultaneously. I am beginner in Parallelizing in c# and i want to know how i should do it, by Multithreading or something like that...

a1 and a2 are integer

quick_sort(a1,0,100);

quick_sort(a2,0,100);

how can i start these function at same time? please write the code for me

网友答案:

Sort both of these "simultaneously".

System.Threading.Tasks.Task.Run(() => quick_sort(a1,0,100));
System.Threading.Tasks.Task.Run(() => quick_sort(a2,0,100));
相关阅读:
Top