Please write complete words. Your txting shorthand makes my brain hurt.
The first thing I see is within your main()
in main.cpp, you're recursively calling main()
. Don't ever do that; a number of compilers won't even compile it. main()
is the entry point from the operating system into your program. Instead, simply move the printing of the menu into the top of the do { ... } while();
loop.
When you declare your static AR::stdcount variable in AR.cpp, assign it an initial value at the same time. E.g. int AR::stdcount = 0;
Avoid using system() calls in your code. There are usually ways to do what you want via function call into a library without executing a separate shell. And specifically avoid coding system("cls");
since the cls command is not portable across shells or operating systems, and even if the user is interacting with the program in a shell/console/terminal, the program should not assume it is the only thing running in, or that it has any control over, the shell/console/terminal. Same goes for system("pause");
-- instead, prompt the user to press a key or enter a value to continue.
In AR::showAll(), why are you incrementing i in the loop-expression, and decrementing t in the loop-body? You're only going to get half the items that way!
At line 15 in GS.cpp, remove the int
declaration, qmarks2 is already declared as an int in GS.h. With the extra int
, you're creating a temporary local variable which masks the instance member. The temporary …