Italy's former prime minister Silvio Berlusconi was sentenced to four years in prison for tax fraud connected to his Mediaset empire Friday, and was banned from holding public office for five years by a Milan court. The sentence, which he is considered certain to stave off by appealing through higher courts, came two days after he announced his retirement from politics. Berlusconi, 76, was accused of having artificially inflated the price of film distribution rights bought by shell companies, then selling these back to Mediaset. The court also sentenced the media tycoon and 10 co-defendants to pay 10 million euros ($13 million) to Italian tax authorities, a statement said. The tax scam helped to create secret overseas accounts and reduce profits to pay fewer taxes in Italy. The prosecution had asked for a prison sentence of three years and eight months for Berlusconi. Prosecutor Fabio De Pasquale said in June that Mediaset costs for the films had been inflated by 368 million dollars from 1994 to 1998, and by 40 million euros from 2001 to 2003. Berlusconi was at "the top of the chain of command in the sector of television rights until 1998", De Pasquale said at the time. He had asked for a prison sentence of three years and four months for Mediaset president Fedele Confalonieri. But Berlusconi's close aide in his business dealings was acquitted on Friday. The verdict came a week after Berlusconi denied at a separate trial that he hosted raunchy parties, had sex with a 17-year-old prostitute or abused his powers by pressuring police officers. In that trial Berlusconi is accused of paying for sex with Moroccan exotic dancer Karima El-Mahroug. He is also charged with abusing his position as prime minister by telling police to release her when she was arrested for petty theft in May 2010. "I never had an intimate relationship of any kind with her," he told the court in only his second appearance at the trial in Milan which began last year and has heard from witnesses describing stripshows at his home. The charge of exploiting an underage prostitute in Italy carries a maximum sentence of three years in prison and abuse of power up to 12 years. Hollywood star George Clooney failed to appear on Friday to give evidence in the sex trial, leading the prosecutor to accuse the defence of seeking to slow the proceedings. The sex trial was one of the last in a series of scandals that helped precipitate Berlusconi's downfall in November 2011, which was finally triggered by a parliamentary revolt against him and a wave of panic on financial markets. Berlusconi, who owns AC Milan football club and three national television channels as well as several private villas, has frequently accused prosecutors, notably in Milan, of plotting against him. He said on Wednesday he would not run in elections early next year and hand his People of Freedom party over to a successor, ending months of uncertainty over his candidacy.