Trouble returning a char array

I have a function Solve(const char first[], char dar[]) that needs to return the full dar array. I've tested this function and it correctly creates dar to what it needs to be. So at the end of the function I have return dar. However, when compiling that line presents this error:

error: invalid conversion from ‘char*’ to ‘char’

I've tried dereferencing dar, which gets rid of the error but of course only returns the first element of the array. Surely there's a way to return the entire array. Anyone know why this error is occuring?
If you are passing char dar[] as a parameter you shouldn't need to return it?

As always try and stay away from C arrays and use something like std::array or std::vector if you are trying to write C++.

http://www.cplusplus.com/reference/vector/vector/
http://www.cplusplus.com/reference/array/array/
Ah, you're right. I've been reading the function's description wrong. Thanks!
Topic archived. No new replies allowed.