Using an array of child processes instead of only one