18 lines
318 B
C
Raw Normal View History

2020-05-01 23:58:52 +02:00
#include <stdio.h>
#include <stdlib.h>
#include <assert.h>
#include <math.h>
int main(int argc, char* argv[])
{
/// Syntaxe ./argv[0] x n
/// Resultat sur stdout : x^n
assert (argc == 3);
int x = atoi (argv[1]);
int n = atoi (argv[2]);
printf ("%.0f\n",pow (x, n));
return 0;
}