Type Conversion in C language MCQs

@T-Bone

This question paper focuses on the "Type Conversion" of the C programming. These Multiple Choice Questions (mcq) should be practiced to improve the C programming skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

This question paper focuses on the "Type Conversion" of the C programming. These Multiple Choice Questions (mcq) should be practiced to improve the C programming skills required for various interviews (campus interview, walk-in interview, company interview), placement, entrance exam and other competitive examinations.

Questions

1. How many type of conversion are there in c?

Mark the correct option

2. Which conversion also called Automatic Type Conversion?

Mark the correct option

3. The following code is an example of? double da = 4.5; double db = 4.6; double dc = 4.9; //explicitly defined by user int result = (int)da + (int)db + (int)dc; printf(""result = %d"", result);

Mark the correct option

4. What will be output for the following code? #include<stdio.h> int main() { int x = 10; char y = 'a'; x = x + y; float z = x + 1.0; printf(""x = %d, z = %f"", x, z); return 0; }

Mark the correct option

5. What will be output for the following code? #include<stdio.h> int main() { double x = 1.2; int sum = (int)x + 1; printf(""sum = %d"", sum); return 0; }

Mark the correct option

6. In Implicit type conversion, If an operand of long int is present then the other operand will be converted to ?

Mark the correct option

7. In Implicit type conversion, If an operand of type long double is present in the expression, then the corresponding operand will also be converted to?

Mark the correct option

8. Which type of conversion is NOT accepted?

Mark the correct option

9. Which of the following typecasting is accepted by C?

Mark the correct option

10. When do you need to use type-conversions?

Mark the correct option

Index of Questions