Researchers and businesspeople are constantly guessing how many jobs robotics and artificial intelligence (AI) will destroy. Their prognostications range from the apocalyptic, to the mild, to the reasonably optimistic.

But what does the average person think? People’s opinions matter: If they see AI as a threat to their job prospects, for instance, they might support politicians, such as US president Donald Trump, who promise to impede change or even bring back the past.

The results from a recently released survey (pdf) by Masayuki Morikawa at Japan’s Research Institute of Economy, Trade, and Industry suggest that how concerned workers are about automation depends highly on their age and educational background.

For the survey, conducted in 2016, over 6,500 Japanese workers, randomly selected, were asked, “What do you think about the impact of AI and robotics on the future of your job?” About 30% answered that they thought they might lose their jobs, 39% thought they probably wouldn’t, and the other 31% weren’t sure.

The strongest predictor of whether someone thought AI would replace them was age: Young people were more anxious about automation. That’s unsurprising, Morikawa says in an article about the survey—after all, AI and robotics are developing gradually, so young people are more likely to be affected in their lifetimes.

Still, the fact that over 40% of 20- to 29-year-old Japanese workers are worried about becoming obsolete is important. As my colleague Allison Schrager points out, workers who face such a threat are ripe for populism, much as workers in the 19th century whose lives were upended by the industrial revolution embraced Marxism, which similarly promised to restore their dignity.

Another factor in how people view the security of their job is education. The 5% of Japanese workers in the sample with graduate degrees were the most confident that AI and robotics would not cost them their jobs—probably, Morikawa thinks, because they believe their skills will complement new technologies. Those with less education were not much more likely to think they would lose their jobs, but they were much more likely to answer “I don’t know” to the question.