2nd task solution added