I have a C++ function that starts as such
void findSolutions(vector<MOVE> & solutions, int board[], int maxPegs){
int newboard[18];
copy(begin(board), end(board), begin(newboard));
...
more code
...
}
I'm trying to copy the parameter "board" into a temporary int array so I don't directly modify the original board. But in copy(), I get the following error from VSCode
no instance of overloaded function "begin" matches the argument list -- argument types are: (int *)
How do I copy the array that gets passed in from the parameter? Thanks