Well it depends on the situation.
If one lives a live void of serious(mortal sins) then they go straight to heaven or purgatory.
However due to our weak human nature we are prone to sins, and thus want to be cleansed to go straight to heaven. It's usually better to confess sins regularly that way you don't have smaller sins(venial sins) building up and making potential purgatory time longer.
If someone is really penitent but CAN'T get a priest then the assumption is that they will be cleansed. However as the church has a system of leaders who represent Christ and lead his flock on earth for him, confession is administered by a priest. This is not to say priests are vastly better than normal people, they are still weak humans prone to sin(they too, confess their sins) but they are the people granted by the Christ through the apostolic succession the power to cleanse others of sin, whereas lay people don't get that power unless they go through seminary.