+ 1

Whats the difference between a compile error and a runtime exception?

21st Dec 2020, 11:02 AM
Yaye
Yaye - avatar
4 odpowiedzi
+ 2
Compile error: The compiler is angry with you coz you wrote the code wrong syntactically. Code does not run at all, plus you get some notes from compiler, where it tries to tell you where (line number), what (warning, error) and why (problem cause). Runtime exception: Code compiles and runs ok, but somewhere in time when someone is using it, the program crashes miserably. This is caused (mostly) by logical error, and/or other faults that are not obviously detectable by the compiler, coz it was not a syntactic fault, rather coder's logic fault, or sometimes, a hardware problem.
21st Dec 2020, 12:46 PM
Ipang
+ 4
An obvious is A compile time error occurs during complication ( eg syntax error ) And runtime error occurs at runtime (division by zero ) you can easily use the search bar for further details
21st Dec 2020, 11:04 AM
Arsenic
Arsenic - avatar
+ 3
Compile error is then which you get when the code is being completed by our compiler. Runtime error is the error which is ignored by the compiler and it is throws while running the program.
21st Dec 2020, 11:06 AM
Krish
Krish - avatar
0
I am still confused
21st Dec 2020, 11:32 AM
Yaye
Yaye - avatar