C Data Types 2 Questions and Answers

C Data Types 2

Showing 10 of 159 questions
1. Find the output void main ( ) { int x=256; char ch=x; printf {%d", ch}; }
  • -128
  • 256
  • 255
  • 0
Show Answer Report
2. The size of an integer variable depends upon
  • width of address bus
  • width of data bus
  • width of control bus
  • width of system bus
Show Answer Report
3. Integers are stored internally in
  • Decimal
  • Hexadecimal
  • Octal
  • Fixed no. of binary digits
Show Answer Report
4. Which of the following is a correct declaration?
  • int age
  • short age;
  • long age;
  • All the above
Show Answer Report
5. Find the output void main ( ) [ printf (%d%d", 4.5, 5}; }
  • 4 5
  • 0 0
  • 0 5
  • None of these
Show Answer Report
6. Which modifier almost doubles the largest value of an integer ?
  • signed
  • unsigned
  • short
  • long
Show Answer Report
7. Find the output void main ( ) enum {x=32767,y}; printf (% %d", x, y); }
  • 32767 32768
  • 32767 -32767
  • 32767 0
  • Compilation error
Show Answer Report
8. In 'C', types are partitioned in to
  • Data types
  • Data types, function types, incomplete types
  • Data types, function types, incomplete types
  • None of the above.
Show Answer Report
9. Macros like INT_MIN, INT_MAX are defined in which header file.
  • stdio.h
  • limits.h
  • dos.h
  • None of these
Show Answer Report
10. Which data type behaves like both integer type and character type ?
  • short int
  • signed int
  • char
  • enum
Show Answer Report
Questions and Answers for Competitive Exams Various Entrance Test