I've made queens problem , it works if I declare the array in which I calculate the solution global, but if I try to dynamically allocate it and pass it to the recursive function using pointers it just prints empty solution infinitely...
I'm trying for hours to figure out whats the problem...
If you were using a global array, all the elements would be initialized to zero. That isn't the case here. All elements of your newed array are random junk.