That's fine and all, but not what was happening.
They had google access and editor hints. Further, I start every interview with "please, ask any questions, we aren't trying to trick you we just want to see if you can code." And I mean it. If someone has a minor problem with remembering syntax or how to declare it I don't really care and will happily let them know how to do that.
Heck, I've even had interactions where a candidate was like "I think there's a method that does x for this" in a language I was unfamiliar with, so I googled up what x was and shared it with them mid interview. "Oh yeah, looks like this is what does x for your language".
There was also some pretty weird behaviors with the camera/screen that caused them to need to touch it fairly frequently (I'm guessing to take over keyboard control from the AI software they were using).
What they were doing, repeatedly, though the interview was writing
`a[i]` then having to change it to `a.get(i)` because they were working with a `List` in java. I get maybe doing that once or twice, but in the course of the interview they did it every single time they needed to pull something out of the list. (and each time needed to touch their screen and take a few minutes to correct it). This is why I strongly suspected cheating. It extended a question that normally takes 15 minutes to 35 minutes. Then the question I ask that usually takes ~45 minutes they completed in 15 with an optimal solution that relies on a data structure I literally only learned about because the interview hints for the question are like "Hey, java has this data structure that makes everything easier".