char GDP1[30];
int GDP;
char natdebt1[30];
int natdebt;
float dpg; /* debt percentage of gdp */
float counter;
printf("Please enter the GDP of the country this company is located in.\n");
gets(GDP1);
GDP=atoi (GDP1);
printf("Please enter the National Debt for the country this company is located in. (Please include unfunded liabilities in addition to the budget deficit) \n");
gets(natdebt1);
natdebt=atoi(natdebt1);
counter=0.01;
while(dpg=GDP*0.01; dpg<natdebt; dpg++)
{
counter=counter++;
};
printf("Debt to GDP is %f percent. \n",counter);
I have been trying to find a way to have a decimal percentage of the national debt (of any country, but I am using the US debt to) and start at one percent of GDP and work up to the national debt (Including unfunded liabilities). But I ran across this C:\QPCCaluclator\original2.c|80|error: expected ')' before ';' token| . I have tried everything, but it won't work. Thanks,
vivo.
