A simple implementation of your ego written in C.