why doesn't #include<conio.h> work in the compiler?
conio.h isn't a standard library with C++ which is most likely why it hasn't been included. It's not needed to provide input/output to the console. According to Wikipedia:
conio.h is a C header file used mostly by MS-DOS compilers to provide console input/output. It is not part of the C standard library or ISO C, nor is it defined by POSIX.