Most criminal cases plea bargain rather than proceed through trial. Typically the defendant agrees to admit (more or less) to having committed some crime or crimes in exchange for a reduced sentence (consequences like jail or prison, fines, classes, a criminal history etc.). The more serious the charged crimes, or the more extensive the defendant's criminal history, the less sentence reduction - the less of a bargain - should be expected.
So what is a "good" plea bargain? Here is a general list of the most common plea agreements in descending order of how good a bargain they can be:
1. Dismissal of all charges with no sentence terms or conditions. This is rare mainly because once a case is started prosecutors are loathe to dump it. An overwhelming lack of evidence usually underlies such a dismissal. Indeed, typically this is less a plea agreement than an acknowledgement by the prosecution that the case should not have been started in the first place.
2. Deferred prosecution, sometimes called a diversion. The prosecution agrees to dismiss the case if the defendant timely completes whatever terms or conditions are agreed upon or otherwise required. The defendant does not admit to having committed any crimes.
3. Deferred sentence, sometimes called a deferred judgment and sentence (or "DJS"). This is like a diversion except the defendant pleads guilty (or no contest if ok'd by the prosecutor and the judge) to something. If he or she timely completes the required terms and conditions, that plea is withdrawn and the case dismissed.
4. Guilty (or no contest) plea to a lesser crime or crimes with lesser/fewer or minimal sentence requirements. For example, the defendant admits to having committed a crime less or different than the ones charged in exchange for no jail/prison or reduced jail/prison. This is by far the most common plea agreement.
5. Open sentence. The defendant admits to a lesser or different crime or crimes and the sentence is left up to the judge. Sometimes a sentence "cap" is agreed to whereby for example the sentence won't exceed a certain period of jail or prison time (subject, as with all sentence terms and conditions, to court approval).
Again, generally speaking, the higher up this list a defendant seeks to climb, the longer (and more expensive) the case will be. Every case is different and nothing in the law is guaranteed. The slightest difference can make all the difference. The more serious the case or the defendant's history, the fewer options.