Numeros de potencia

an anonymous user · December 05, 2023
#include <math.h>
#include <stdio.h>

int main(){
    double num, potencia, r_potencia, raiz;
    printf("Ingresa el numero: \n");
    scanf("%if", &num);
    printf("potencia: \n");
    scanf("%if", &potencia);
    r_potencia = pow(num, potencia);
    raiz = sqrt(num);

    printf("%if elevado a la potencia %if es %if \n", num, potencia, r_potencia);
    printf("La raiz cuadrada de %if es %if \n", num, raiz);

    return 0;
}
Output

Comments

Please sign up or log in to contribute to the discussion.