Ver Mensaje Individual
  #3 (permalink)  
Antiguo 04/08/2010, 09:20
iwkillyou
 
Fecha de Ingreso: julio-2010
Mensajes: 153
Antigüedad: 13 años, 9 meses
Puntos: 1
Respuesta: llamada de funciones [facil]

prueba esto


Código C:
Ver original
  1. #include <stdio.h>
  2. float div(float x, float y)
  3. {
  4.     return x / y;
  5. }
  6.  
  7. int main(int argc, char **argv)
  8. {
  9.     float x, y;
  10.     printf("Introduce x: ");
  11.     scanf("%f", &x);
  12.     printf("Introduce y: ");
  13.     scanf("%f", &y);
  14.    
  15.     printf("%f/%f = %f\n", x, y , div(x, y));
  16.     return 0;
  17. }