SINGAPORE -- Talented people who immigrate to Canada don't necessarily abandon their home countries, Prime Minister Justin Trudeau told students in Singapore Thursday, when he had to defend the consequences of this country's efforts to draw the best and the brightest from overseas.

During the one-hour question-and-answer session at the National University of Singapore, a student from Vietnam asked the prime minister how he could ensure that new trade deals Trudeau is seeking don't rob other countries of entrepreneurs and skilled workers.

Given the right policies, a brain drain one year could become a "brain gain" another year for any country if people are freely able to move, Trudeau replied.

"That capacity to have a world in which there are greater opportunities is I think what we need to get to," he said. "The idea that only certain Western countries should have a quality of life that is at the top of the ladder and everyone else should be providing resources to those countries is completely wrong."

Canada wants to compete for global talent for its burgeoning technology and artificial-intelligence hubs and the federal government is trying hard to make the country attractive to both investors and skilled workers. Trudeau told the Singapore students that Canada is not averse to trying to keep foreign students in the country after they graduate from Canadian schools -- but he said the same people are just as likely to leave again as changes in the workforce take some workers to multiple careers in multiple cities and countries.

That movement of workers, technological shifts in labour, and the impact on workers has followed Trudeau throughout his 10-day trip to Europe and Asia. On Friday, Trudeau will travel to Papua New Guinea for the annual APEC summit of leaders of 21 Pacific Rim countries, where labour-force disruption is expected to be a key theme.

In Paris, Trudeau talked about voters' nervousness about the loss of traditional jobs as a factor in the rise of nationalist politicians. And throughout the last three days in Singapore, he has argued that politicians who look to hold on to old industries, or protect their workers from the future, are doing their people a disservice.

Canada, he said, is doubling down on the future.

Doubling down on the future, though, brings other problems, as another student pointed out. Parts of Silicon Valley in the United States have been flooded by highly paid tech workers, gentrifying cities and making some places unaffordable for people who aren't making elite incomes.

(The issue hung over a meeting Trudeau had earlier this year with Amazon CEO Jeff Bezos when Toronto was still in the running for the company's second headquarters, but federal officials behind the scenes felt it would be difficult to turn down billions of dollars in investment and 50,000 jobs.)

On Thursday, Trudeau said there are already challenges with rising housing prices in Canada; his government has tried to cool some of the hottest markets in country, such as Toronto and Vancouver.

Pulling in new tech investment could worsen things and Trudeau said the government is thinking through how to manage the situation "so that Canadians continue to afford their homes and afford places to live in our great cities."

Trudeau has been in Singapore for the annual ASEAN summit, organized by a 10-nation bloc that combined is Canada's sixth-largest trading partner. Trudeau made clear his government's wish to launch free-trade talks with ASEAN, a group that includes the Philippines, Indonesia, Brunei, Singapore, Malaysia, Thailand, Vietnam, Laos, Cambodia and Myanmar.

That raises questions for Trudeau about navigating human-rights issues with some ASEAN members, such as the Philippines and Myanmar -- issues that Trudeau said were not unlike concerns Canada has with Saudi Arabia or China.

"Canada will always try to engage, be very direct about always and consistently standing up for human rights and at the same time try and create a relationship that allows us to perhaps advance, nudge, move forward in a way that will be better for their citizens as well as ours," Trudeau said. "It's a very careful balancing act that we're constantly engaged in."