Aller au contenu

Mathc initiation/Fichiers h : c54fc

Un livre de Wikilivres.


Sommaire


Installer et compiler ces fichiers dans votre répertoire de travail.

c00g.c
/* --------------------------------- */
/* save as c00g.c                    */
/* --------------------------------- */
#include     "x_a.h"
#include      "fg.h"
/* --------------------------------- */
int main(void)
{
double n = 3;

 clrscrn();
 
 printf("     (n+2)! - n!   = [(n+2)(n+1)  n!] - n!   \n" 
        "                   = [(n+2)(n+1) - 1]   n! \n\n"
        
        "    With  n        = %.0f   \n\n" 
        "  (n+2)! - n!      = %.0f     \n"
        " [(n+2)(n+1)-1] n! = %.0f \n\n\n",
                    n ,
           F_mns2a(n),
           F_mns2b(n) );
 stop();
 
 return 0;
}
/* --------------------------------- */
/* --------------------------------- */


Exemple de sortie écran :
     (n+2)! - n!   = [(n+2)(n+1)  n!] - n!   
                   = [(n+2)(n+1) - 1]   n! 

    With  n        = 3   

  (n+2)! - n!      = 114     
 [(n+2)(n+1)-1] n! = 114 


 Press return to continue.