Break The code 2015 problem CKTFEV

I tried to consider almost all the test cases for the question CodeChef: Practical coding for everyone still the solution was not being accepted on the grounds of wrong answer , the solution is attached herewith :

#include<stdio.h>
#include<stdlib.h>
int main()
{
int testcases,r,o,s,totalrun[1000],i=0,j,k=0;
double p;
double totalrate[1000];
scanf(“%d”,&testcases);
while(testcases–)
{

	scanf("%d %d %d",&o,&r,&s);
	
	if(o >50 || r > 36 || s > 36 || o <= 0 || r <= 0 || s <= 0)
	{
		exit(0);
	} 
	totalrun[i++]=(o*r)+s;
	//printf("%d\n",totalrun[i-1]);
	if(o==50)
	{
		totalrate[k++]=r*1.0;	
		printf("\n%.2f",totalrate[k-1]);
	}
	else
	{
		totalrate[k++]=(totalrun[i-1]/(o+1.0));
		printf("\n%.2f",totalrate[k-1]);
	}
	
}

/*for(j=0;j<k;j++)
{
	printf("\n%.2f",totalrate[j]);
}*/
return 0;

}

Please consider the code and find the possible mistakes …

Seems like overkill, you do not need arrays totalrate[1000] and totalrun[1000], they can be replaced with two variable.

I will be able to exactly pin-point your error once the problem is moved into practice section. Meanwhile you can check my easier ACcepted solution here.