Want this question answered?
error
An example of semantic error is: a+b = c.
Use the debugger to locate the error.
Logic errors in any computer language may be difficult to find. Languages that are object oriented can make it harder because you have to follow the object activations, which are separate from plain structural code. However, it isn't any more difficult in C++ than some other OO languages to find logic errors; in all cases it can be difficult.
It's a syntax error, which is detected during compilation, yes.
error
An example of semantic error is: a+b = c.
A system error is an error that originates from the operating system or other low-level operation. Every system error is identified by a single integer value which is specific to the platform. In Windows, for instance, you will find a list of all error codes in the <winerror.h> header file.
Nothing, c--3 is syntactical error.
In C and C++ you may use isc_interprete to get a human-readable description of the error. If you use IBPP API, it thorws exceptions containing a description of error.
Error is not used. You might have meant stderr or errno.
Difficult to find? No. Difficult to see? Definately.
The logic error is more difficult to detect and correct than the syntax error. The syntax error will fail compilation, and you will get a (relatively) clear indication of where the problem lies. The logic error, on the other hand, will give you a successful compilation, and a program that appears to run, although it will not give you the correct results. This causes you to perform (unit) testing and debugging of various levels.
There is an error in line 42.
Use the debugger to locate the error.
Logic errors in any computer language may be difficult to find. Languages that are object oriented can make it harder because you have to follow the object activations, which are separate from plain structural code. However, it isn't any more difficult in C++ than some other OO languages to find logic errors; in all cases it can be difficult.
in trpezoidal rule for numerical integration how you can find error