Click here to Skip to main content
15,896,501 members

Comments by Member 13248267 (Top 1 by date)

Member 13248267 8-Jun-17 11:20am View    
jum(p,(n/2)+1,n);


The problem was the 2nd call of the function. I am a beginner and, I must say, I never used the debugger and I don't really know how it works. Though, I saw that the problem was at the call of the function inside the function. To verify my code, I usually use "//" or "/* */" and run it to see if it works. My mistake was that, inside the "jum" function, I only verified the first call, it worked and didn't verify the 2nd one. I still am not really sure what caused the code to crash. What is the difference between having (n/2)+1 and n/2 (I must say that (n/2)+1 shows the answer that I wanted)) ? And, would you mind telling me what I did wrong, as I am still learning and still couldn't find "the problem".