Assignment

changed code according to the test requiremment