Page 28 - Prosedur
P. 28

KODE POINTER






                                                                                                                                            Prosedur



                                                                                                                                             Rekursif








                                                   void s_helper


                                                        (int x, int *accum)


                                                   {


                                                        if (x <= 1)  return;


                                                        else {


                                                            int z = *accum * x;


                                                            *accum = z;


                                                            s_helper (x-1,accum);


                                                        }


                                                   }
   23   24   25   26   27   28   29   30   31   32   33