You are not supposed to change
find compiling? If so, you can debug the compiled programme like
./generate 1000 50 | debug50 ./find 127
(or any number you'd like to use). In
helpers.c, using the IDE, you can set a breakpoint (click left of the line number where you want to enter the debugger's interactive mode), show variable contents, and proceed in the code line by line if you want.
I still did some printf debugging, as sometimes it is easier to dump an array than to view it in the debugger interface.
For example, I printed the content of the array before and after sorting (with a line "Before:" and "After:" above the values), and tested that for small arrays (<10 elements) to check for non-sorted parts or elements missing from the sorted version, for example from duplication of other elements.