The used graphic functions and the header file
graphics.h belong to the ancient
Borland Turbo C - Wikipedia[
^] and
Turbo C++ - Wikipedia[
^] IDE and compiler for creating MS-DOS programs.
To use them with Linux you have to install a compatible library like
libgraph - Summary [Savannah][
^] or
The SDL_bgi and libXbgi Libraries[
^].
You might use these libraries for learning purposes. But they should be not be used for release applications and it might be better to use a more recent technology instead of investing time on an ancient graphics interface that nobody uses anmyore.