A compile time error is when you don't follow the correct syntax of the language.
for example, in English, you can have a noun, a verb, and an object:
I painted the house.
If i wrote a sentence that had a noun, a verb, another verb, and an object:
I painted swallowed the house.
That violates the rules of the grammar. a verb followed by a verb is not allowed. this would be a compiler error.
Java has VERY SPECIFIC rules on what kinds of things are allowed to follow other things. It's called the Java Language Specification, commonly called the JLS.
For example, the token 'if' must be followed by an open paren character. if you wrote "if Integer X = new Integer();", you would get a compiler error, because you break the rules of the grammar.
a runtime error happens when the code is grammatically correct, but 'something bad' happens at runtime. An obvious example is a division by zero, when the divisor is supplied by the user. In pseudo-code:
get dividend
get divisor
print dividend / divisor
this can be written as legal java code. it is perfectly OK to divide one number by another. However, if the user inputs a 0 for the divisor, that code can't run. You get an error/exception. there is no way for the compiler to know what the user will input, so it can't catch an error like that.