Added conway algorithm