The fragile transitional government under Mohamed owes its survival to the backing of the international community and only governs a few districts of the capital, relying heavily on the 9,000-strong African Union Mission (AMISOM) to do so.
Shebab Islamic militants control virtually all of south and central Somalia and a large part of the capital.
But in mid-February pro-government forces launched a huge offensive on several fronts, including in Mogadishu, where they have reported good progress.
"With AMISOM's help we're gaining ground every day," Mohamed said in an interview Thursday.
He said he needs about a year to finish the job and that is why his government, due to step down in August, announced on Monday that it will continue in power for another 12 months.
"We were only appointed recently... We still need some more time to defeat the Shebab. That is our priority," said Mohamed, who was appointed in November 2010.
By then he expects to have finished "restoring security to Mogadishu and probably kicking the Shebab out of the rest of the south of the country."
Then authorities will be in a position to draw up a draft constitution and a new law on political parties, he said, adding "we will establish good governance and put in place a transparent system and we will revamp public services and foster national reconciliation."
The mandates of the government and the parliament were both supposed to end in August after an earlier two-year extension. The mandate of President Sharif Sheikh Ahmed, who was elected by parliament in early 2009, was also supposed to end in August.
Aides to Sharif say the extension of the government's mandate automatically entails a prolongation of the presidential mandate.
Parliament decided unilaterally in early February to prolong its mandate by three years, drawing criticism from the international community that thinks the achievements to date of Somalia's 550 lawmakers have been meagre.
Mohamed was appointed to replace Omar Abdirashid Sharmarke who quit after a protacted dispute with Sharif that paralysed Somalia's institutions for several months.
"Our soldiers and our public servants have been paid for the past three months and that hadn't happened for the past 20 years," he said.
"Look at the town, the people who are coming back," he said, mentioning renewed commercial activity in the government-held zone in Mogadishu as well as work carried out by the municipal authorities, such as street lighting, road repair and rubbish collection.
"If we leave now before we finish our task, I am convinced the Shebab will be the ones who benefit," he said.
"Things move forward only slowly. I can't achieve miracles. I need more time."