Quote:
How do you make the program stop to display the results,because getchar() doesn't seem to work,other then system("pause"),and I read it's not a good idea to use system calls.
You can either run your program for the console / command-line (where your program will exit, but the output will still be visible) or use a different function at the end. stdio.h provides several functions that require hitting enter before moving on. None of them are completely ideal for that purpose, but at least they're standardized. In the real world, non-GUI programs usually just exit, as they are usually run from the console anyway (or they're intended to just disappear once they're done).