0 votes 0 votes What is the type of error (earliest phase) identified during the compilation of the following program ? #include <stdio.h> main( ) { int x, y, z; x = y = z = 10.3; printf(“%c”, x); } Compiler Design compiler-design + – vaishali jhalani asked Dec 10, 2016 edited Dec 10, 2016 by ManojK vaishali jhalani 774 views answer comment Share Follow See all 6 Comments See all 6 6 Comments reply thor commented Dec 10, 2016 reply Follow Share No lexical error No syntax error Semantic error Reported 0 votes 0 votes Kapil commented Dec 10, 2016 reply Follow Share Why Semantic Error ? 0 votes 0 votes thor commented Dec 10, 2016 reply Follow Share In C, It will be typecasted as $x = y = z = 10$, and ASCII character corresponding $10$ will be printed. So, no problem in C. 1 votes 1 votes thor commented Dec 10, 2016 reply Follow Share But it would cause semantic error if it $x,y$ and $z$ were initialized as floats. rt?? 1 votes 1 votes Habibkhan commented Dec 10, 2016 reply Follow Share Ya implicit type conversion is available in C..So no issue in C..But in languages which it does not support this feature..So there problem will come in type checking which is a part of semantic analysis phase.. 1 votes 1 votes srestha commented Dec 10, 2016 reply Follow Share yes, it will be error because it want to print int value in %c 0 votes 0 votes Please log in or register to add a comment.