can i further improve the code? |
Probably the biggest improvement will come from finding, downloading, and using a modern C++ compiler. Any compiler that allows
#include<iostream.h>
is much too outdated to be using. And once you start using that modern compiler make sure you enable, at minimum, compiling in C++11 mode, if not C++14 mode to take advantage of the modern C++ features available in the current C++ standards.
The next necessary improvement will come from finding and consistently using some kind of indentation style.
https://en.wikipedia.org/wiki/Indent_style
Next, I recommend you stop using the outdated conio.h header file and anything related to it, unless absolutely necessary (it's not really necessary in this program).
Lastly, never, Never, NEVER use gets(), this C function is so dangerous that it has actually been removed from the latest C and C++ standards.
So to sum it up you need to start learning Modern C++ not pre-standard C++ from 20 years ago and avoid using all those C'isms such as C-strings, strlen(), getch(), etc. and start using real C++ features such as std::string, std::vector, std::array, etc..