Page 124 - 2622_Delhi Police Public School_C-6
P. 124

2.  Rewrite the following statements correctly.
                         a.  PRINT("Welcome")


                         b.  print("Result,result")

                      3.  Surf the Internet and find more information about features of Python.


                      4.  Competency-based/Application-based questions:
                         a.   Aryan has written the following code to perform the multiplication of two numbers and print the
                            result:
                           x, y == 10, 20
                           z = x * y
                          print(z)
                            Do you think the code is correct? Why or why not?
                         b.  Lara has taken two numbers as input by using the following statements:
                            x = input("Enter the first number")
                           y = input("Enter the second number")
                              But when she tries to perform the addition operation, she gets a concatenation of numbers. Why
                            is she not getting the correct output?
                         c.   Jiva is working on a scientific research project in which she has to calculate the population growth
                            of the bacteria over multiple time intervals. The population of the bacteria doubles every hour
                            under ideal conditions. Which python operator should she use to get the desired result?
                         d.   Leena is writing some logical expressions in which she wants to reverse the result of a logical
                            expression. Which Python operator she can use to achieve this?

                       Explore in the Lab                                      21 st  Century   #Information Literacy
                                                                                       #Technology Literacy
                                                                                   Skills
                To
                Subject  Coding

                 Write a Python program to:
                 1.  calculate the value of the following expression if a = 5, b = 3, and c = 7:
                     (a * b) + (c // a) - (b % c)
                 2.  check whether X is greater than Y and the sum of these two numbers is even.
                 3.  combine the following words and display in one line with a single space:
                     Python
                     Programming
                     Language
                 4.  input five numbers and display their average.
                 5.  convert inches into centimetre.
                 6.  convert Celsius to Fahrenheit using the formula: (Celsius * 1.8) + 32
                 7.   convert kilometre unit to metre

              For The Teacher
                  Discuss about Python programming modes with the students.
                  Go through all the other topics covered in this chapter.
                  Tell the students about the importance of Python.



                122     Premium Edition-VI
   119   120   121   122   123   124   125   126   127   128   129