Basic algorithms written in coffee (to stay sharp).