Page 217 - Computer Science V2.0 Class 11
P. 217

Fig 8.3c: Python prints a triangle on the execution of the function triangle()
                 ●  The control returns to line 32 (in the global frame) following the line which invoked the function triangle().

                 ●  On  execution  of  line  32,  a  blank  line  is  printed  and  the  control  moves  to  line  33  which  invokes  the  function
                   rhombus().
                 ●  On execution of the function rhombus(), a rhombus is printed as shown in Fig 8.3d.
























                                      Fig 8.3d: Python prints a rhombus on execution of the function rhombus()
                 ●  Next, the control returns to line 34 which follows the line which invoked the function rhombus().

                 ●  On execution of line 34, a blank line is printed and the control moves to line 35 which invokes the function triangle().
                 ●  On execution of the function triangle(), another triangle is printed (see Fig 8.3e).























                                      Fig 8.3e: Python prints a triangle on execution of the function triangle()

                                                                                             Introduction to Functions  203
   212   213   214   215   216   217   218   219   220   221   222