Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void exponencial(int *a, int k,double *exp) {
- int *cont = new int;
- *cont = 0; double *expaux = new double; *expaux = 0.0;
- int*factor = new int; int numero; double termino;
- for (int i = 0; i < k; i++)
- {
- factorial(cont, factor);
- numero = pow(*a, *cont);
- termino = numero / *factor;
- *expaux += termino;
- *cont++;
- }
- *exp = *expaux;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement