add min dist problem and modified main and readme