Patterns assignment


not able to solve it