how come i get segmentation faults on this code
Code:
#include <stdio.h>
#include <stdlib.h>
float bonus(void);
void main() {
float b;
printf("Enter a # to be incremented: ");
b=bonus();
printf("The incremented is now %.2f",b);
}
float bonus(void) {
float i;
scanf("%f",i);
return(i+1);
}