MIAMI (AP) -- Pop singer Justin Bieber pleaded guilty Wednesday to misdemeanor charges of careless driving and resisting arrest seven months after his arrest in Miami Beach following what police initially called an illegal street drag race.
The 20-year-old pop star's plea deal with prosecutors, detailed at a court hearing, includes a 12-hour anger management course, a $50,000 charitable contribution and fines. The deal allows Bieber to avoid a driving under the influence conviction.
Bieber was not present at the hearing before Miami-Dade County Judge William Altfield. Defense attorney Mark Shapiro said Bieber had already given the $50,000 to a local children's charity.
Bieber was arrested early Jan. 23 in Miami Beach after what police described as an illegal street race between Bieber's rented Lamborghini and a Ferrari driven by R&B singer Khalil Amir Sharieff. Neither was charged with drag racing and there was little evidence they were even exceeding posted speed limits.
Alcohol breath tests found Bieber's level below the 0.02 limit for underage drivers, but urine tests showed the presence of marijuana and the anti-anxiety drug Xanax in his system. Bieber was also charged with resisting arrest after a profanity-laced tirade against police officers, as well as driving on an expired license.
The urine test itself became a battle between media companies, including The Associated Press, that sought access to video of the test and Bieber's lawyers arguing it was an invasion of privacy. Ultimately, Altfield ordered the video released with sensitive portions blacked out. Other police video depicted Bieber walking unsteadily during a sobriety test.
In July, Bieber resolved another criminal case by pleading no contest to a misdemeanor vandalism charge for throwing eggs at a neighbor's house in Los Angeles. In that case, Bieber agreed to pay more than $80,000 in damages and meet a number of other conditions.
Bieber is also charged in Toronto with assaulting a limousine driver in late December. His lawyers have said he is not guilty in that case.
Also in Miami, Bieber is being sued by a photographer who says he was roughed up while snapping pictures of the singer outside a recording studio.
The Canadian-born Bieber shot to stardom at age 15, with his career overseen by two music industry heavyweights, singer Usher and manager Scooter Braun, after initially gaining notice through YouTube videos. He was nominated for two Grammy Awards for his 2010 full-length album debut "My World 2.0."