it seems i can only return an integer value from a subprogram? i need a float value returned is there something i'm missing here? i wrote this quick block of code to show you what i mean. say i type in 6.67 in the get_z function it then returns to the main function and assigns it to z. when i print z in the main function it prints as 6.0000 etc

Code:
#include <stdio.h>
#include <stdlib.h>

int main()
{
  float z;
  
      z=get_z();
      printf("z in main fuction = %f\n", z);
      
      system("PAUSE");
      return 0;
}


int get_z()
{
  float z;
      
      printf("please enter # for z: ");
      scanf("%f", &z);
      
      return z;
}