Your information is confusing. What 5 people and what 8 chairs? And I don't know how to get that answer either!
There are 10C6 ways to pick the chairs to be occupied by 6 people. There are 6 ways to fill the end seats with men. There are 4! ways to arrange the remaining people in the 4 remaining seats.
(10*9*8*7/4*3*2) * 6 * 4*3*2 = 10*9*8*7*6 = 30240