<html>
  <head>
    <meta content="text/html; charset=ISO-8859-1"
      http-equiv="Content-Type">
  </head>
  <body text="#000000" bgcolor="#FFFFFF">
    <div class="moz-cite-prefix"><br>
      Hello,<br>
      <br>
      There is no such notion in python.<br>
      But the closest are iterators and generator functions.<br>
      <br>
      Cheers<br>
      Karim<br>
      <br>
      On 18/04/2013 19:06, abdelkader belahcene wrote:<br>
    </div>
    <blockquote
cite="mid:CAF3f0sQ_rsdKwaEOCmFHEeEwpVUaNUo-pOYgoqYA_F-k0CftcA@mail.gmail.com"
      type="cite">
      <div dir="ltr">
        <div>
          <div>
            <div>
              <div>
                <div>
                  <div>
                    <div>Hi everybody,  <br>
                      <br>
                    </div>
                    I am new to python  and I am discovering it.<br>
                  </div>
                  I know C well,<br>
                </div>
                and want to know if python knows how to manage Pointers<br>
              </div>
              like pointer to function  here is a C example how to write
              it in python<br>
            </div>
            <div>Intergration with trapeze method<br>
            </div>
            <div><br>
            </div>
            When we write Trapeze   ( at the compilation level) we don't
            know which functions <br>
          </div>
          Fonc  to handle.      Here for example we use  sin and a user
          defined  F1<br>
        </div>
        The program is attached too<br>
        <div><br>
          <div>
            <div>
              <div>
                <div>
                  <div>
                    <div>
                      <div>
                        <div>
                          <div>#include <stdio.h><br>
                            #include <math.h><br>
                             <br>
                            double F1 (double x){ <br>
                                    return x*x; <br>
                            }<br>
                            double Trapeze(double Fonc(double ), <br>
                                                            double left,
                            double right, double step){<br>
                              double X1, X0, Y0, Y1, Z = 0;    <br>
                              for(X0=left; X0 < right ; X0 = X0 +
                            step) {<br>
                                X1 = X0 + step;<br>
                                Y1 = Fonc(X1);    Y0 = Fonc(X0);<br>
                                Z  += (Y1 + Y0) * step * 0.5;<br>
                              }<br>
                               return Z;<br>
                            }<br>
                            int  main(){ <br>
                              double y;<br>
                              y=Trapeze(sin, -2.5, 3.2, 0.1);<br>
                              printf("\n\tValue for sin  is : \t %8.3lf
                            ", y);<br>
                              y=Trapeze(F1, 0, 3, 0.1);<br>
                              printf("\n\tValue for F1 is : \t %8.3lf ",
                            y);<br>
                              return 0;<br>
                            } <br>
                            /**<br>
                                Value for sin  is :         0.197 <br>
                                Value for F1 is :          9.005<br>
                                */<br>
                          </div>
                          <div>
                            thanks a lot<br>
                          </div>
                        </div>
                      </div>
                    </div>
                  </div>
                </div>
              </div>
            </div>
          </div>
        </div>
      </div>
      <br>
      <fieldset class="mimeAttachmentHeader"></fieldset>
      <br>
    </blockquote>
    <br>
  </body>
</html>