5 5 votes Which of the following has the compilation error in C? int n = 17; char c = 99; float f = (float)99.32; #include <stdio.h> Programming in C programming-in-c isro2015 + – Nisha kumari 8.8k views answer comment Share Follow Print See 1 comment 1 1 comment reply JashanArora commented Dec 7, 2019 reply Follow flag The char data type stores any string of letters, numbers, and symbols. It can even accept signed numbers. 0 0 replyShare Please log in or register to add a comment.
Best answer 6 6 votes None of them not even giving any compiler warning even with strict C standard. Arjun answered Oct 15, 2015 Arjun comment Share Follow See all 4 Comments 4 4 Comments reply Digvijay Pandey commented Oct 15, 2015 reply Follow flag According to ISRO, answer is D option. 0 0 replyShare amarVashishth commented Oct 15, 2015 reply Follow flag there goes a satellite in Bay of Bengal. 25 25 replyShare Arjun commented Nov 13, 2015 reply Follow flag @Digvijay I suppose given the choices one should go with D because it is a preprocessor directive :) 2 2 replyShare anandhomkumare commented Jul 25, 2024 reply Follow flag 😂😂😂😂 0 0 replyShare Please log in or register to add a comment.
7 7 votes Yes ; all r seeming correct; But a,b,c options are absolutely correct. Now come to option D;; Now Suppose User has installed TC & then he had move this into another location say D drive without intimating this change to TC. Then while compiling it will get err bcz it will search Library file STDIO.H in C:/TC/INCLUDE which is not available der due to users move operation;Hence it is one of the possibilities to Get Compiler Err. Reference:http://www.infolet.org/2013/08/solving-unable-to-open-include-file-stdio.h-conio.h-iostream.h-c0s.obj.html?m=1 Gate Tud answered Jun 14, 2016 • edited Jun 14, 2016 by Gate Tud Gate Tud comment Share Follow See 1 comment 1 1 comment reply Arjun commented Jun 29, 2016 reply Follow flag Good. But never say anything like this is any IIT interview. They will kick you out even if you spell Turbo C. "stdio.h" is a standard header file defined by C standard. And "include <stdio.h>" is also standard way of including the header file. A programmer/user need not have to worry about the location of the header file here- it is up to the compiler to find that. 4 4 replyShare Please log in or register to add a comment.
4 4 votes By looking at them i would like say there is no error. Here ans is #include<stdio.h> which is not appropriate but compared to other .Now See int n=17; //No error since int value char c=99 ;// char even take int so no error float=(float)99.32 //No error float is type-casting #include<stdio.h>//If you have single statement"#include<stdio.h>" Compiler Simply generate error Undefined reference to main() ManojK answered May 26, 2016 ManojK comment Share Follow 0 reply Please log in or register to add a comment.
1 1 vote By looking at them i would like say there is no error. Here ans is #include<stdio.h> which is not appropriate but compared to other .Now See int n=17; //No error since int value char c=99 ;// char even take int so no error float=(float)99.32 //No error float is type-casting #include<stdio.h>//If you have single statement"#include<stdio.h>" Compiler Simply generate error Undefined reference to main() Source - https://gateoverflow.in/46861/which-following-compilation-error-float-float-%23include-studio Regina Phalange answered Apr 1, 2017 Regina Phalange comment Share Follow 0 reply Please log in or register to add a comment.