Is it possible to get the results from a C++ program and print it out in OW app?

Is it possible to get the results from a C++ program and print it out in a web app?

Theoretically yes.
Practically, you’ll need to wrap this into a c# plugin that launches the C++ program and either listens to its exit code or have the c++ application itself create an output file/communicate directly with your app.
If you have access to the code of the C++ program - You can have it create an output file in a shared directory (e.g., %localappdata%) or even open a WebSocket/HTTP socket server
or connect to an HTTP server opened by your app