N.Y. ELN. LAW § 6-162 : NY Code - Section 6-162: Primary; New York City, run-off

In the city of New York,
  when  no  candidate  for  the  office  of  mayor,  public  advocate   or
  comptroller  receives  forty  percent  or  more of the votes cast by the
  members of a political party for such  office  in  a  city-wide  primary
  election,  the  board  of elections of such city shall conduct a run-off
  primary election between  the  two  candidates  receiving  the  greatest
  number of votes for the same office.