I have written a program in C which runs correctly and I can see all the correct output in the console window that I would expect. But at the very end when the program should end I get a Microsoft error box "myprogram.exe has encountered a problem and needs to close. We are sorry for the inconvenience."
The console window then says "*** process returned -1073741818 ***".
Why is it returning this number? The last line of my main function says
so I would expect it to return 0.Code:return 0; }