Computer Science 12th Chapter 9 - Elements of C Questions Bank

Computer Science 12th Chapter 9 - Elements of C Questions Bank
Computer Science 12th Chapter 9 - Elements of C Questions Bank

Computer Science 2nd Year Chapter 9 - Elements of C Solved MCQs, Important Short Questions and Long Questions Bank

MCQs

Please select the right answer.

1. Variables are created in :





2. ____has higher order of precedence :





3. &&, || and ! are : 





4. ___ is arithmetic operator :





5. ___ is logical operator :






6. ___ is logical operator :






7. ___ is not a logical operator : 





8. ___ is not an arithmetic operator :





9. ___ is used to declare a real type variable :





10. ___ logical operators is unary operator :





11. ___ returns False if X = 5 and Y = 10 : 





12. ___ returns True If X =5 and Y = 10 : 






13. ___ statement is valid for initializing variable(s) :






14. ___ statements is not valid :





15. _________ defines a set of values and a set of operations on those values





16. ___data type offers the highest precision :





17. ___data types is used to store real value :






18. ___data types takes only one byte is memory : 






19. ___elements of program in not token : 






20. ___is a modulus operator :





21. ___is arithmetic expression :





22. ___is equivalent to !(p> =q) : 



23. ___is increment operator :





24. ___is not a valid variable name :





25. ___is not a valid variable name :






26. ___is not relational operator : 





27. ___is valid character constant :





28. ___is valid character constant :






29. ___is valid statement to add 1 to variable x :






30. ___is valid variable name :






31. ___not a logical operator : 





32. ___operators is used to join two conditions : 






33. ___returns Falst if X = 2 and Y = 3 : 





34. ___returns True if X = 2 and Y =3 : 






35. ___statements is valid for declaring variable(s) :






36. ___symbols is used for logical AND operator : 





37. ___symbols is used for logical NOT operator : 





38. ___symbols is used for logical OR operator :





39. ___valid assignment statement :






40. +,-,/,% and * are : 





41. a + = b is equivalent to





42. A memory location with some data that cannot be changed is called.





43. A quantity whose value cannot change during execution of program is called :





44. A quantity whose value may change during execution of program is called :





45. A relational expression may return value :





46. A variable can be declared for ____ data type 





47. a+ =b is equivalent to:





48. All of the following are valid expressions EXCEPT:





49. An arithmetic expression may consist of :






50. An expression may consist of : 





51. An expression that uses relational expression is represented by :





52. An identifier whose value can be changed during execution of a program is called






53. Assigning a value to a variable at the time of its declaration is called :





54. C is a strongly typed language, this means that : 





55. How many bytes the char data type takes in memory





56. How many bytes the float data type takes in memory





57. How many bytes the int data type takes in memory





58. How many bytes the long data type variable takes in memory :





59. How many bytes, the double data type variable takes in memory : 






60. How many keywords are in C : 





61. How many logical operators are in C :





62. How many relational operators in C : 






63. If a = 19, then after execution of the statement b = a %5; the value of b will be :





64. If simple assignment statement is “x = x + 2;”, then its equivalent compound  assignment statement is :





65. If x = 3, then after executing the statement “x = x − −;”, the value of x will be : 





66. In C, the comments are written in program between : 





67. In C, the maximum length of variable name is :





68. Initialization of a variable refers to 





69. Long double data type of C language requires ____ bytes of memory





70. Memory location with some data that can be changed is called:





71. Relational operators are used to





72. The ‘int’ data type variable has a range of :





73. The double data type variable has a range of :






74. The double data type variable has precision of : 





75. The exponential notation consists of:





76. The expression 10%3 has a value equal to:





77. The float data type variable has a precision of :





78. The float data type variable has a range of :





79. The float, long float and double data types are known as:





80. The integer, long and short data types are known as:





81. The logical not (!) operator is denoted as : 





82. The logical NOT operator, denoted by !, is a : 





83. The modulus operator is used for:





84. The names used to represent variables, constants , types functions etc are called





85. The number of bytes used by double data type in C is.





86. The number of bytes used by int data type in C is?





87. The predefined data types of C language are called 





88. The predefined words of the programming language that are used for special  purposes in the source program are called : 





89. The reserve words cannot be 





90. The symbol = represents :





91. The true value return by relational expression is represented by :





92. The value of 15%2 is 






93. The value of expression 11%3 is : 





94. The value of expression 11%3*5 is : 





95. The value of expression 2%3 is : 





96. The value returned by expression 3+3*5 will be : 





97. The words used to write the statements of a program are called





98. There are ____ types of identifiers in C language 





99. Variable names cannot begin with a (n):






100. What happens when the result of a calculation exceeds the capacity of data type?






101. What will be the value of ‘x’ after executing the following statements :  int x = 2;   x + = x ++;





102. What will be the value of ‘y’ after executing the following statements :  int y = 3  y = y + (++y);





103. When the result of the computation of two very small numbers is too small to be  represented, this phenomenon is called : 





104. Which character cannot be used in a variable name :





105. Which is a numeric data type?





106. Which of the data type offers the highest precision : 





107. Which of the following are valid variable names?






108. Which of the following characters cannot be used as first character of a variable  name :





109. Which of the following data can be stored by “int” type variable :






110. Which of the following is a valid character constant : 





111. Which of the following is an arithmetic expression : 





112. Which of the following is not a valid variable name :





113. Which of the following is NOT arithmetic operator?






114. Which of the following is relational operator : 





115. Which of the following is used to declare a real type variable :





116. Which of the following operators has lowest precedence?





117. Which of the operator has lowest precedence 





118. Which one is a valid variable name 





119. Which one is not an example of standard data type of C language 






120. Which one is not an example of standard identifier 





121. Which range refers to signed int data type of C language 





122. Which range refers to unsigned int data type of C language 






Short Questions

1. What do you known about the data type in C language?
2. Define ! (logical NOT) operator?
3. Define constant.
4. Define data type for characters?
5. Define data types for floating-point numbers?
6. Define data types for integers?
7. Define identifiers?
8. Define logical operators?
9. Define numeric constant?
10. Define standard data types?
11. Define string constant. Give some examples.
12. Define the statement j += 5; ?
13. Define the working with division operator?
14. Define type casting and its types.
15. Define variable declaration.
16. Define variable initialization? How is a variable initialized?
17. Differentiate between "area" and area in C language.
18. Differentiate between declaring and defining a variable.
19. Differentiate between increment and decrement operators?
20. Differentiate between Logical ‘AND’ and Logical ‘OR’ operators?
21. Differentiate between prefix and postfix increment operator?
22. differentiate between single-line comments and multi-line comments?
23. How are comments added on multiple lines?
24. How are comments added on single line?
25. How can you differentiate keyword from identifier?
26. How does an arithmetic underflow occur?
27. How is explicit casting performed?
28. How many types of identifiers are used in C language?
29. How much memory does different data types require (Any three)?
30. Is it compulsory to declare all variables in C program?
31. List any three data types in C.
32. Name and give the purpose of basic 
33. What are binary operators?
34. What are compound assignment operators?
35. What are floating point constants?
36. What are integer constants? Give some examples.
37. What are relational operators?
38. What are the comments?
39. What are the keywords?
40. What are the operators?
41. What are the standard identifiers?
42. What are the values of a and b after execution? Let a and b be two variables of type double and int respectively:
43. What are the variables?
44. What are two ways to use data types in C?
45. What are unary operators?
46. What are user-defined identifiers?
47. What do you known about the data type in C language?
48. What does the symbol= do in C?
49. What is a character constant?
50. What is an assignment operator?
51. What is an identifier? Give some examples of identifier.
52. What is an operators?
53. What is arithmetic expression?
54. What is arithmetic overflow?
55. What is arithmetic underflow?
56. What is character data type?
57. What is constant?
58. What is defining a variable?
59. What is garbage value?
60. What is initializing a variable?
61. What is keyword? Give some examples.
62. What is meant by case-sensitive language?
63. What is meant by declaring a variable in C?
64. What is meant by overflow?
65. What is meant by strongly typed language?
66. What is meant by underflow?
67. What is specified in variable declaration?
68. What is standard identifier? Give some examples.
69. What is ternary operator?
70. What is the data type?
71. What is the modulus (remainder) operator?
72. What is the operator’s precedence?
73. What is the use of assignment operator?
74. What is the use of assignment statement?
75. What is the use of increment operator?
76. What is user-defined identifier? Give some examples.
77. What is variable? Why is it used in programs?
78. Where can you add the comments in programs?
79. Which data types are used for storing floating point data?
80. Which problems may occur while working with floating point numbers?
81. Why are comments used in C program?
82. Why comments do not affect the size of program?
83. Why does cancellation error occur?
84. Why is C known as strongly typed language?
85. Why is it important to assign a data type to a variable?
86. Why is it important to specify correct data type for variables?
87. Why is it important to specify correct data type for variables?
88. Write any three rules for declaring variables in C.
89. Write the legal characters for an identifier.
90. Write the order of operator’s precedence from highest to lowest?
91. Write two types of constants in C language with examples.

Long Questions

1. Explain the importance of elements of C language?
2. What is a character set? Explain the character set of C language?
3. What is an Identifier? Also write down its two different types.
4. What are the Keywords / Reserve words in c language?
5. What is a variable? Also write down the rules for naming a variable?
6. What is meant by variable declaration and initialization? Explain with the help of examples?
7. What is a constant? Also discuss its different types.
8. What is a data type? Also write about character data types.
9. Discuss different Numeric data types used in C language.
10. Discuss different floating point or real data types used in C language.
11. Define the Cancellation Error, Arithmetic Underflow, Arithmetic Overflow, Integer Underflow and Integer Overflow.
12. What are comments? Also discuss its different types.
13. What is an expression? Also describe operator and operand?
14. Describe arithmetic expression? Also discuss its different modes.
15. What are relational expressions?
16. What are Logical Expressions? Also discuss its different operators.
17. What is Increment and decrement operator? Explain with the help of examples.
18. What is assignment statement and assignment operator?
19. What is operator precedence? List the operators used in C language according to their precedence level.
20. What is an operator’s associatively? Explain with example.
21. What is meant by type casting? Explain in detail.

Post a Comment (0)
Previous Post Next Post