It depends. Pedestrians in a crosswalk have the right of way, so drivers must yield. Suppose the pedestrians not yet in a crosswalk. Then, they should yield to drivers until it’s safe to enter the crosswalk.
Pedestrians do not have an unlimited right to barge into a crosswalk whenever they like. They should wait until it’s safe.
Cars can do more damage. They always have a general duty to “exercise due care to avoid colliding with any pedestrian.” When the pedestrian is a “child or any obviously confused, incapacitated or intoxicated person,” due care bumps up to “proper precaution.”
Pedestrians have specific rights at crosswalks. Crosswalks can be at intersections of streets or “elsewhere.” At intersections, they can be marked or unmarked.
At an intersection, an unmarked crosswalk is basically the imaginary extension of a sidewalk across the street. This is true, even if the sidewalk doesn’t continue on the other side. That means an unmarked crosswalk requires some kind of sidewalk near the intersection.