This program is returning inf" as the output in c :     #include <stdio.h>
    void main()
    {
    	int i, n,a;
    	float result=1;
    	float sum;
    	a=1;
    	sum=0;
    	printf("Enter a number:\n");
    	scanf("%d",&n);
    
    	for (i=0;i<=n-1;i++)
    	{
    		result=result*i;
    		sum = a + (i/result);`enter code here`
    
    	}
    
    	printf("%.2f is the answer\n",sum );

}


The code here is meant to find the sum of factorial.The output comes as "inf is the answer". I don't know how to solve this. New to programming.
