I have a C++ code (hello world code that prints "hello world!" in a text file).
#include <iostream>
#include <fstream>
using namespace std;
int main(int argc, const char * argv[]) {
// insert code here...
ofstream myfile;
myfile.open ("Hello_World.txt");
myfile << "Hello World! This is a test.\n";
myfile.close();
return 0;
}
I want to see if it's possible to compile my C++ code on shinyapp.io and then execute the compiled file on the server and get the "Hello_World.txt" file? If not, how should I compile my code on my local machine so it can be executed in shinyapp.io once I transfer the compiled code on server?
I am more concerned about the approach (compiling a Fortran or C++ code on local machine and running on shinyapp.io). My goal is to extend the approach for more complex code in future.