Basic Algo : Classes and interface