Great question - thanks for posting!
In the "old days" before Java 9, even a "hello world" program required a class declaration (try explaining that to new coders), a "public static void main(String args)", and finally, a System.out.println("Hello"); - followed by that crucial semicolon and two closing braces. Then, save the file with the same name as the class, then compile, then run.
Typos, problems with uppercase/lowercase, general confusion, and you could spend a significant chunk of a class period getting their first line of code to work, without even explaining what the other two lines of code really do (the public class and public static void main seem like mystical incantations from a Java spell book...).
Maybe I'm exaggerating, but not much
Now, we can fire up JShell, and type:
(Notice no semicolon needed at the end of a single command!) JShell will reply with Hello! - and just like Python's Shell, you can evaluate expressions, test a few lines of code to see how Java actually works without coding a "driver" class, try loops, even build interactive, windowed apps (a few chapters in...):
All of this is possible in JShell - it's the Python-like beginner-friendly gateway to Java we've been waiting for (for a couple of decades).
If you haven't played around with JShell in JDK 9, I highly recommend it, especially for teachers.
Thanks again for the great question, and I hope you'll give JShell a try, especially when working with new coders.