First idea of a generation algo