write different types of error with example?
Answers
Answer:
there are three types of errors in java.syntax error,logical error,runtime error.
Explanation:
the examples are: System.out.println(syntax error)
Systm .out.prnln(runtime error)
for loop();(logical error..HOPE IT HELPS YOU
Answer:
there there are three types of errors
1. syntax error------your there is something wrong in the syntax or the format of your program. violation of any grammatical rules causes syntax error
2. logical error-----logical errors are the result of wrong logic of the program for example if the problem is to calculate the sum of last three numbers then the loop is not running five times it will produce a wrong results.
3. runtime error-------the some of the examples of the runtime error number by 0, are index out of bound, arithmetic error like square root of negative numbers and etc.........
HOPE IT HELPS