action for the slide puzzle implemented.