semantic errors in a program are
Answers
Answered by
0
compile time errors this error occurs when the statement is not meaningful
Answered by
27
ANSWER
................
THE ERROR AS FOLLOWS
........................
1.Syntax errors: Errors that occur when you violate the rules of writing C/C++ syntax are known as syntax errors. This compiler error indicates something that must be fixed before the code can be compiled. All these errors are detected by compiler and thus are known as compile-time errors.
Most frequent syntax errors are:Missing Parenthesis
(})Printing the value of variable without declaring it
Missing semicolon like this://
C program to illustrate // syntax error
#include<stdio.h>
void main() { int x = 10;
int y = 15; printf("%d", (x, y)) // semicolon missed }
................................
Run-time Errors : Errors which occur during program execution(run-time) after successful compilation are called run-time errors. One of the most common run-time error is division by zero also known as Division error. These types of error are hard to find as the compiler doesn’t point to the line at which the error occurs.
For more understanding run the example given below.// C program to illustrate// run-time error#include<stdio.h>void main(){ int n = 9, div = 0;
................
THE ERROR AS FOLLOWS
........................
1.Syntax errors: Errors that occur when you violate the rules of writing C/C++ syntax are known as syntax errors. This compiler error indicates something that must be fixed before the code can be compiled. All these errors are detected by compiler and thus are known as compile-time errors.
Most frequent syntax errors are:Missing Parenthesis
(})Printing the value of variable without declaring it
Missing semicolon like this://
C program to illustrate // syntax error
#include<stdio.h>
void main() { int x = 10;
int y = 15; printf("%d", (x, y)) // semicolon missed }
Error:
error: expected ';' before '}' token................................
Run-time Errors : Errors which occur during program execution(run-time) after successful compilation are called run-time errors. One of the most common run-time error is division by zero also known as Division error. These types of error are hard to find as the compiler doesn’t point to the line at which the error occurs.
For more understanding run the example given below.// C program to illustrate// run-time error#include<stdio.h>void main(){ int n = 9, div = 0;
Similar questions