At a Bill and Melinda Gates Foundation event earlier this week, Microsoft founder Bill Gates regaled an audience with stories about meetings with President Donald Trump — including Trump’s lack of basic knowledge about two sexually transmitted infections that affect millions of people around the world.

“Both times he wanted to know if there was a difference between HIV and HPV, so I was able to explain that those are rarely confused with each other,” Gates said, according to footage obtained by MSNBC’s Chris Hayes, host of All In.

More disturbingly, while Trump couldn’t distinguish between the common viruses, he could remember details about the appearance of Gates’s 22-year-old daughter, Jennifer Gates.

“It was actually kind of scary how much he knew about my daughter’s appearance,” Gates said. “[My wife] Melinda didn’t like that.”

To set the record straight for the president, here’s a quick primer on HPV and HIV. While the viruses can both be spread through sex, they have radically different biologies and health outcomes.

HPV, explained in brief

The human papillomavirus, or HPV, is the most common STD in the country, affecting 79 million Americans. Almost every sexually active person will have HPV at some point in their lives.

It’s one of a handful of STDs that are known to cause cancer. According to the Centers for Disease Control and Prevention, the number of HPV cancers diagnosed has gone up from 33,369 in 2008 to 38,793 in 2012. HPV now causes nearly all cervical cancers, 95 percent of anal cancers, and 70 percent of oropharyngeal cancers.

But there are more than 200 strains of the virus. Most are considered low-risk, with little chance of leading to cancer. Only 14 “high-risk” strains are known to cause oral or genital cancers. The good news is that most of these high-risk strains are targeted by the HPV vaccine. It’s recommended for boys and girls ages 9 to 26, but only six in 10 girls and half of boys get the shot.

HIV, explained in brief

An estimated 1.1 million people in the US and 36.7 million people worldwide are living with the human immunodeficiency virus, known as HIV. Unlike HPV, which affects just about everybody, in the US, the burden of HIV falls mainly on gay and bisexual men. The virus weakens a person’s immune system by destroying the cells that fight disease and infection.

There’s no cure or vaccine for HIV, but the discovery of antiretroviral treatments turned an HIV diagnosis from a death sentence into a chronic illness. These medicines have helped many more people who are diagnosed live normal lives with the disease.

Importantly, however, these drugs don’t cure patients; they only suppress the HIV virus to the point that it’s undetectable in the blood. That means there’s still a very small chance that people taking these treatments can pass on the virus to others. And if people stop taking their medicines, their “viral load” rises again. This puts them at risk of developing AIDS and increases the risk of transmitting the virus to others.

Gates says he dissuaded Trump from creating a commission to question vaccine safety

The first meeting between the billionaires took place in December 2016, around the time Trump was thinking of setting up a commission to investigate the safety of vaccines.

“In both of those two meetings, [Trump] asked me if vaccines weren’t a bad thing because he was considering a commission to look into ill effects of vaccines,” Gates said.

“And somebody, Robert Kennedy Jr., was advising him that vaccines were causing bad things and I said, ‘No, that is a dead end, that would be a bad thing, do not do that.’”

Trump never went ahead with the commission, and it seems like we may have Gates to thank, at least in part.

Clarification: A previous version of this article stated that HPV is the only STD known to cause cancer. In fact, Hepatitis B and C and HIV are also known to raise the risk of cancer.