What will the function rewind() do?
Answer: D
rewind() takes the file pointer to the beginning of the file. so that the next I/O operation will take place at the beginning of the file.
Example: rewind(FilePointer);
Enter details here
What will be the output of the program?
#include
#include<math.h>
int main()
{
float i = 2.5;
printf("%f, %d", floor(i), ceil(i));
return 0;
}
Answer: C
Both ceil() and floor() return the integer found as a double.
floor(2.5) returns the largest integral value(round down) that is not greater than 2.5. So output is 2.000000.
ceil(2.5) returns 3, while converting the double to int it returns '0'.
So, the output is '2.000000, 0'.
Enter details here
How many macros are defined in the header file stdarg.h?
Answer: C
No answer description available for this question.
Enter details here
What will be the output of the following C code?
void main()
{
div_t res;
res = div(34, 4);
printf("quotient part = %d\n", res.quot);
printf("remainder part = %d\n", res.rem);
}
Answer: B
div_t div(int n, int d) used to divide n (numerator) by d (denominator). div_t is a structure defined in
int quot;
in rem;
Enter details here
The macro which is used to find the maximum value of an unsigned integer is _________
Answer: C
No answer description available for this question.
Enter details here
Which of the following library functions returns the time in UTC (Greenwich mean time) format?
Answer: C
No answer description available for this question.
Enter details here
Select the function that reads or sets location dependent information.
Answer: B
No answer description available for this question.
Enter details here
A preprocessor command
Answer: C
No answer description available for this question.
Enter details here
C preprocessor
Answer: D
No answer description available for this question.
Enter details here
Is standard library a part of C language?
Answer: B
The C standard library consists of a set of sections of the ISO C standard which describe a collection of header files and library routines used to implement common operations, such as input/output and string handling, in the C programming language. The C standard library is an interface standard described by a document; it is not an actual library of software routines available for linkage to C programs.
Enter details here