Montana Rep.-elect Greg Gianforte was sentenced to 40 hours of community service and 20 hours of anger management Monday as punishment for body slamming a reporter on election eve.

During an appearance before Gallatin County Justice of the Peace Rick West, the newly elected congressman was given a six-month deferred sentence and ordered to pay $385 in fines and court costs. He has until Nov. 28 to complete the community service and anger management.

Gianforte can have the deferred sentence erased from his record, if he does not violate the conditions of deferral for the next six month, West said.

The judge initially sentenced Gianforte to four days in jail, then modified that punishment to community service and anger management classes after learning the congressman-elect was not eligible for the jail work program because his conviction was for a crime of violence.

It "is not my intent that you spend four days in jail," West told Gianforte. "I don’t think that will serve the community or the taxpayers."

The judge emphasized, however, that the congressman-elect's actions were "totally unacceptable."

Gianforte pleaded guilty to misdemeanor assault for the May 24 attack on Guardian reporter Ben Jacobs, who asked the Republican congressional candidate about his stance on the House GOP's health care plan, provoking his rage. Audio of the attack was captured on Jacobs' recorder, and three Fox News reporters corroborated the reporter's account.

Jacobs was treated and released at a Bozeman hospital following the incident. His elbow was injured in the attack and his glasses were broken.

Gianforte apologized to Jacobs in court on Monday, and invited him to an interview in Washington, D.C., "when you are ready." He also has paid $4,464.97 in restitution.

Gianforte has not yet been sworn in, after being elected Montana's new congressman in a special election May 25. He replaces Ryan Zinke, who is now the nation's Interior secretary.

"I just want to say I'm sorry," Gianforte told Jacobs during the 45-minute hearing in Gallatin County Justice Court.

Jacobs had earlier taken the witness stand to describe the attack, but also to say he has forgiven the congressman-elect.

“I have asked questions of hundreds of politicians: congressmen, senators and even the man who is now our president,” Jacobs read from a prepared statement. “Mr. Gianforte’s response was to slam me to the floor and start punching me.”

Jacobs said the attack “thrust me into a national spotlight I did not seek or desire."

Worse yet, he said, Gianforte’s campaign released a “defamatory” public statement insisting Jacobs was the aggressor. The candidate made no public statement for more than 24 hours, until after his victory over Democrat Rob Quist was secured.

To date, Gianforte has not explained why his campaign released the false statement, or addressed its contents.

Monday's hearing was live-streamed on ktvh.com, and concluded with the congressman-elect's attorneys filing a motion to prevent Gianforte from having to submit to the formal booking, fingerprinting and mug-shot-taking process. Briefs on that motion are due Friday.

More From Missoula Current