$5$
18. There are 30 students standing in a row, and from left to right, they are wearing hats in the order of "red, yellow, blue, red, yellow, blue......". The PE teacher asks the students to count off from left to right as "1, 2, 1, 2, 1, 2.....", and those who count off 2 step forward. Among the remaining students, those wearing red hats step back. At this point, the students are divided into 3 rows, and in the middle row, there are $\qquad$ people wearing blue hats.