c++ while arista de un cubo

#include <conio.h>
#include <math.h>
#include <stdio.h>

int main()
{
float arista ;
printf ("\n introduce la arista:");
scanf ("%f", &arista);
while(arista<=0)
 {
  printf ("\n ERROR: la arissta debe ser mayor que cero:");
  printf ("\n introduzca arista:");
  scanf ("%f", &arista);
 }
 printf ("\n el area de un cubo arista %F es: %f", arista,6 * pow(arista,2));
 return 0;
}

Comentarios

Entradas populares