Code:
int main()
{
// character*80 project_name
// character*80 control_file
char project_name[80];
char control_file[80];
char tmpbuf[80];
int nwgt_start, nwgt_end, nwgt_step;
int pow_start,pow_end,pow_step;
FILE *st; // define your I/O or FILE channel == 10
// open(10,file="setup.dat",form="formatted", status="old")
st = fopen("setup.dat", st);
// 200 format(a)
// read(10,200) project_name
fgets(project_name, 80, st);
// write(6,200) project_name
printf("%s", project_name); // printf=to screen=6, %s="a format"
// read(10,200) control_file
fgets(control_file, 80, st);
// write(6,200) control_file
printf("%s", control_file);
// read(10,*) nwgt_start,nwgt_end,nwgt_step
fgets(tmpbuf, 80, st); // Read the line of ints. %d = int conversion
sscanf(tmpbuf, "%d %d %d", &nwgt_start, &nwgt_end, &nwgt_step);
// write(6,*) nwgt_start,nwgt_end,nwgt_step
printf("%d %d %d", nwgt_start, nwgt_end, nwgt_step);
// read(10,*) pow_start,pow_end,pow_step
fgets(tmpbuf, 80, st); // Read the line of ints. %d = int conversion
sscanf(tmpbuf, "%d %d %d", &pow_start, &pow_end, &pow_step);
// write(6,*) pow_start,pow_end,pow_step
printf("%d %d %d", pow_start,pow_end,pow_step);
// close(10)
fclose(st);
}