solving mp 1 and 0