A runtime error normally crashes your program. A try/catch block lets you intercept the problem and keep running.
You broke the rules of the Java language. Missing semicolon, typo in a keyword, unclosed brace.
The code runs fine — it just produces the wrong answer. Java has no idea anything is wrong; it's doing exactly what you told it to do.
The program started fine but then hit something unexpected — bad input, a missing file, an out-of-range index. Java throws an exception.
try/catch block. Without one, the program crashes.Tip: press a quick-pick button to set the number, then Run. Switch modes to see the same input produce two very different outcomes.