Cod sursa(job #333746)
Utilizator | Data | 23 iulie 2009 17:28:40 | |
---|---|---|---|
Problema | Ridicare la putere in timp logaritmic | Scor | 10 |
Compilator | cpp | Status | done |
Runda | Arhiva educationala | Marime | 0.26 kb |
#include <iostream.h>
#include <fstream.h>
#include <math.h>
int main()
{
ifstream f("lgput.in");
ofstream g("lgput.out");
int n,p,z;
f>>n>>p;
f.close();
z=pow(n,p);
g<<z%1999999973;
g.close();
return 0;
}