Mumbai, India (CNN) -- President Obama said Sunday that Pakistan is not making progress against militants "as quick as we'd like."
Pakistan has a lot of potential, but has some "extremist elements within it," the president said. "The problem has to be addressed."
Obama was responding to a question from a student at a town hall meeting in Mumbai. He said that India has the biggest stake in its neighbor's success.
"Hope over time trust develops, dialogue begins," he said. "The U.S. stands to be a partner in that process, but can't impose that."
After the meeting, Obama headed to New Delhi, where he is expected to meet Indian Prime Minister Manmohan Singh. He will also address the nation's parliament.
Obama's visit to India is part of a 10-day tour in Asia. His first stop -- India's financial hub of Mumbai -- was the scene of a deadly terror attack of November 2008 that killed 164 people.
The attack, which was blamed on Pakistan-based militants, derailed a fragile peace process between New Delhi and Islamabad.
"Obama's Mumbai visit is symbolic of the perspective India and the United States share on terrorism," said former Indian army chief V.P. Malik. "It should lead to strengthening of counterterrorism efforts."
Obama will also travel to Indonesia, South Korea and Japan during the tour.