Page 15 - Touchcode_C7_Flipbook
P. 15

3.  Which  of  the  following  helps  the  computer  to  understand  the  type  of  operations  to  be
                         performed?
                         a.  Variable                                 b.  Data type

                         c.  Data validation                          d.  None of the above

                     4.  Which of the following is required to declare a variable?
                         a.  Name of the variable                     b.  Data type
                         c.  Both a and b                             d.  None of the above


                     5.  Which of the following are the data types?
                         a.  Integer                                  b.  Floating-point number
                         c.  Character                                d.  All of the above


                 B.  State whether the following statements are true (T) or false (F).

                     1.  Data validation ensures that the data entered by the user is valid value.

                     2.  Boolean is a subtype of integer data type.


                     3.  Syntax of declaring an integer variable is specific to the programing language.


                     4.  ‘float’ stores whole numbers and integer value.


                     5.  Modulus operator returns the remainder.

                 C.  Fill in the blanks.

                                        HELP BOX    initialization, data, undefined, valid, real

                     1.  A variable is declared but is not initialized has an ........................... value.

                     2.  Assigning a value to a variable is ........................... .
                     3.  Data validation ensures that the data entered by the user is ........................... .

                     4.  Every value needs to be assigned to a specific ........................... type.

                     5.  Floating point hold ........................... numbers with decimal values.

                 D.  Match the following:

                     1.  Integer data type                          a.  Used for single letters
                     2.  Character (or char)                        b.  *

                     3.  Addition operation                         c.  int a=1;
                     4.  Subtraction operation                      d.  +

                     5.  Multiplication operation                   e.  -


                                                                                          Variables in Real Life   13
   10   11   12   13   14   15   16   17   18   19   20