Page 78 - Information_Practice_Fliipbook_Class11
P. 78

19.  What will be the output produced on evaluating the following expression?
              int(123.987)
              a.  123                  b. 123.0               c. 124                 d. 124.0
          20.  Which of the following functions is used to display the description of a in-built function?
              a.  desc()               b. DESCRIBE()          c. help()              d. HELP()
          21.  What will be the output produced on evaluating the following expression?
              eval(50+75)
              a.  125                  b. '50+75'             c. Error               d. No Output
        B.  State whether the following statements are True or False:
           1.  The output produced by invoking the print() function multiple times, appears on separate lines (by default).    __________
           2.  The identifiers are case-insensitive.                                                   __________
           3.  Blank spaces within an identifier are allowed.                                          __________
           4.  In Python, the variables are created as soon as a value is assigned to them.            __________
           5.  Keywords can be used for naming identifiers in a Python program.                        __________
           6.  An operand should always have a constant value.                                         __________
           7.  The text beginning with a hash character is called a comment.                           __________
           8.  A variable has to be assigned a value before it is used in an expression.               __________
           9.  Python does not allow us to use multiple variables in a single assignment statement.    __________
          10.  Python considers user inputs as strings.                                                __________
          11.  In a Python program, a variable can refer to values of different data types at different times.   __________
          12.  In a Python program, a string can only be created by enclosing a set of characters in double quotes.   __________
        C.  Fill in the blanks.
           1.  A ____________ cannot be used for any purpose other than the one defined by the language.
           2.  An identifier should begin with an uppercase or lowercase alphabet, or an ____________.
           3.  ____________ are symbols used to separate various tokens in a statement.
           4.  A ____________ is an identifier that denotes a value.
           5.  An ____________ operator associates a variable with the object on the right-hand side.
           6.  The input() function reads the text entered by a user until a ____________ is encountered.
           7.  The ____________ function is used to print the value of a variable.
           8.  To convert the data type of input() to an integer, the ____________ function is used.
        D.  Answer the following questions:
           1.  Is space included in the character set of Python?
           2.  Mention five different tokens used in Python?
           3.  Which of the following are valid Python identifiers? Justify your answer.

              Asia&Europe, Item-name, while, For, False, your_choice, input(), output
           4.  Does the operation performed by a particular operator depend on the type of data on which it is being performed?  Justify
              your answer.
           5.  A variable is an example of an identifier.
               Is the above statement correct? Justify your answer.
           6.  State the rules for forming a variable.
           7.  Write a statement in Python to assign the value 15.6 to the variable weight.
           8.  Consider the following statement:
              choice = 'yes'
              Answer the following questions.
              (i)  Identify the operator and the operands.


          64   Touchpad Informatics Practices-XI
   73   74   75   76   77   78   79   80   81   82   83