metodo factorial

Upload: jaime-arregoces

Post on 07-Jul-2018

212 views

Category:

Documents


0 download

TRANSCRIPT

  • 8/18/2019 MeTodo Factorial

    1/2

    using System;

    using System.Collections.Generic;

    using System.Linq;

    using System.Text;

    namespace ConsoleApplication7

    {

      class Program

      {

      static void ain!string"# args$

      {

      dou%le &act;

      'nt() n;

      Console.*rite!+di,ite un numero -+$;

      n 'nt().Parse!Console./eadLine!$$;

      &act 0actorial!n$;

      Console.*rite!+el &actorial de -{12- es -{(2-+3 n 3 &act$;

      Console./ead4ey!$;

    2

      pu%lic static 5ou%le 0actorial!'nt() num$

      {

      5ou%le &(;

      &or !int i (; i 6 num; i$

      {

      & & 8 i;

      2

  • 8/18/2019 MeTodo Factorial

    2/2

      return ! & $;

     

    2

      2

    2