A set of basic algorithm