first version to pass the tests