Solution third assignment