Dinesh has several squares and regular pentagons, all with side length $ 1$. He wants to arrange the shapes alternately to form a closed loop (see diagram). How many pentagons would Dinesh need to do so?
[img]https://cdn.artofproblemsolving.com/attachments/8/9/6345d7150298fe26cfcfba554656804ed25a6d.jpg[/img]
1. **Understanding the Problem:**
   Dinesh wants to arrange squares and regular pentagons alternately to form a closed loop. Each shape has a side length of 1. We need to determine how many pentagons are required to complete this loop.

2. **Analyzing the Geometry:**
   - A regular pentagon has internal angles of \(108^\circ\).
   - A square has internal angles of \(90^\circ\).
   - When arranged alternately, the sum of the internal angles at each vertex where a square and a pentagon meet must be \(360^\circ\) to form a closed loop.

3. **Calculating the Angles:**
   - Each vertex where a square and a pentagon meet will have an angle contribution of \(90^\circ\) from the square and \(108^\circ\) from the pentagon.
   - The total angle at each vertex is \(90^\circ + 108^\circ = 198^\circ\).

4. **Forming the Closed Loop:**
   - To form a closed loop, the total sum of the angles around the loop must be a multiple of \(360^\circ\).
   - Let \(n\) be the number of squares and pentagons. Since they are arranged alternately, there will be \(n\) squares and \(n\) pentagons.
   - The total angle sum around the loop is \(n \times 198^\circ\).

5. **Finding the Number of Shapes:**
   - For the loop to close, \(n \times 198^\circ\) must be a multiple of \(360^\circ\).
   - Simplifying, we get:
     \[
     n \times 198^\circ = k \times 360^\circ \quad \text{for some integer } k
     \]
     \[
     n \times 198 = k \times 360
     \]
     \[
     n = \frac{k \times 360}{198}
     \]
     \[
     n = \frac{k \times 180}{99}
     \]
     \[
     n = \frac{20k}{11}
     \]
   - For \(n\) to be an integer, \(k\) must be a multiple of 11. The smallest such \(k\) is 11.
   - Therefore, \(n = \frac{20 \times 11}{11} = 20\).

6. **Conclusion:**
   - Dinesh needs 10 squares and 10 pentagons to form a closed loop.

The final answer is \(\boxed{10}\) pentagons.