RIO DE JANEIRO — Kanak Jha, the Milpitas 16-year-old who was the youngest male ever to qualify for table tennis in Olympic history, lost in the first round of the games.

Jha lost Saturday to Iranian Nima Alamian 4-1 in the best-of-seven match. Jha struggled with nerves in the first game, losing it decisively to Alamian, 24, but he bounced back to win the second. Jha couldn’t build momentum after that, losing the next three games. After hitting long on match point, Jha flipped his racket into the air and caught it.

He’ll return for the team event.

“The last two games were very close games,” Jha said. “I had a chance in all of them. But when it got close, he has a really good serve and set himself up for the first attack. And then when it’s close — like the 9-9, 10-10 — I got a little more nervous and he would attack.”

American Lily Zhang fared much better to advance to the round of 32.

Zhang, a Cal student from Palo Alto, demolished Venezuela’s Gremlis Arvelo 4-0, a huge improvement on Zhang’s Olympic debut four years ago in London, when she lost as a 16-year-old in the first round. The 20-year-old Californian also swept Portugal’s Jieni Shao 11-4, 11-9, 11-9, 11-6.

“I felt like I had the advantage in the rallies,” Zhang said. “Beforehand, I knew how to play her since she’s a lefty and I had strategy.”

This is the third consecutive Olympics a U.S. woman reached the round of 32 as Zhang followed Chen Wang in 2008 and San Jose’s Ariel Hsing in 2012.

Zhang’s coach, Massimo Constantini, said the Palo Alto High alumna controlled her nerves much better than in London. When asked about her preparations for the next game, he said she was taking a nap.

Zhang faces Korea’s Hyowon Suh on Monday morning.

The Associated Press contributed to this report.