I was wondering if it was possible to access data from an array inside a threaded function after it has finished executing?

Take this example:

#include <iostream>
#include <boost/thread.hpp>

using namespace std;

void workerFunc(int start){
	int arr[5];
	int i;

	for(i = 0; i < 5; i++){
		arr[i] = start;


int main(){
    boost::thread workerThread(workerFunc, 3);

    return 0;
After workerFunc has finished, how could I access the array arr? Is there any way to get (3,4,5,6,7) back into main()?

Thank You