The Prince makes this law in an effort to restore peace and order to Verona and to put an end to the bloodshed. He hopes that the threat of death will deter the Montagues and Capulets from engaging in further conflicts and that this will allow the city to move forward and heal from the tragic events that have occurred.
However, the law proves to be ineffective in preventing further violence. In fact, it only serves to escalate the conflict and ultimately leads to the tragic deaths of Romeo and Juliet.