Just a few q's for ya. Don't Have A Clue if this is right.
Reading a file, using toupper and two dimensional arrays for this part of the program. This is what I have.
section[i]=toupper(section[i]);
for(i=0; i !=EOF; i++)
{
for(x=0; x !=EOF;xi++)
{
input_status=fscanf, "%s %s %ld %lf %c\n",&last[i], &first[i], &emp_id[i], &wg_hr_py[i][x], &section[i]);
}
}
emp_counter=i;
return(emp_counter);

I have to sort my arrays. I have two dimentional arrays to sort and strings to sort. I am getting Alot of errors when I run this part of my program. I just can't figure it out.
for(i = 0; i<emp_counter; i++)
{
for[j = 0; j<emp_counter; j++)
{
if(strcmp(last[j - 1] > last[j]))
{
strcmp(temp_last, last);
strcpy(temp_last, last[j - 1]);
strcpy(last[j - 1], last[j]);
strcpy(last[j], temp_last);

temp_emp_id = emp_id [j - 1];
emp_id [j - 1] = emp_id [j];
emp_id [j] = temp_emp_id;

strcmp(temp_first, first);
strcpy(temp_first, first[j - 1]);
strcpy(first[j - 1], first[j]);
strcpy(first[j], temp_first);

temp_wage = wg_hr_py [j - 1][0];
wg_hr_py [j - 1][0] = wg_hr_py [j][0];
wg_hr_py [j][0] = temp_wage;

temp_hours_worked = wg_hr_py [j - 1][1];
wg_hr_py [j - 1][1] = wg_hr_py [j][1];
wg_hr_py [j][1] = temp_hours_worked;

temp_weekly_pay = wg_hr_py [j - 1][2];
wg_hr_py [j - 1][2] = wg_hr_py [j][2];
wg_hr_py [j][2] = temp_weekly_pay;

strcpy(temp_section, section[j - 1];
strcpy(section[j - 1], section[j]);
strcpy(section[j], section);

}
}
}
Thanks alot