I just start playing around with C++ and how to combine it with Emacs. This website on cpp-programming and Intro to C++ are the starting point for me. The extended aim is to be able to write some C++ codes that can be part of R.

Standard Hello World!.

#include <iostream>

using namespace std;

int main(){
    cout << "Hello World!" << endl;
    return 0;
}

To compile this basic code in Emacs then use make with the following:

A nice description on using Makefile can also be found here doc.ic.ac.uk

code  cpp 
comments powered by Disqus