There are two cases to consider:
Case 1: All the boys sit together:
Treat the 5 boys as a single unit. Thus, we have 5 boys (as a block) and 4 girls, which makes 5 units in total. The number of ways to arrange these 5 units is \( 5! \), and within the block of boys, the boys can be arranged in \( 5! \) ways. Hence, the total number of arrangements in this case is:
\[
5! \times 5! = 120 \times 120 = 14400.
\]
Case 2: No two boys sit together:
Arrange the 4 girls first, which can be done in \( 4! \) ways. This creates 5 possible spaces where the boys can sit. We can place one boy in each of these 5 spaces, and the 5 boys can be arranged in \( 5! \) ways. Thus, the number of arrangements in this case is:
\[
4! \times 5! = 24 \times 120 = 2880.
\]
Therefore, the total number of arrangements is:
\[
14400 + 2880 = 17280.
\]