On a stormy night ten guests came to dinner party and left their shoes outside the room in order to keep the carpet clean. After the dinner there was a blackout, and the gusts leaving one by one, put on at random, any pair of shoes big enough for their feet. (Each pair of shoes stays together). Any guest who could not find a pair big enough spent the night there. What is the largest number of guests who might have had to spend the night there?
To determine the largest number of guests who might have had to spend the night at the party, we need to consider the worst-case scenario where the maximum number of guests cannot find a pair of shoes big enough for their feet.

1. **Label the guests and their shoes:**
   Let the guests be labeled as \( P_1, P_2, \ldots, P_{10} \) and their corresponding shoes be labeled as \( S_1, S_2, \ldots, S_{10} \), where \( S_i \) is the pair of shoes belonging to guest \( P_i \).

2. **Determine the shoe size constraint:**
   Each guest \( P_i \) can only wear shoes \( S_j \) where \( j \geq i \). This means that guest \( P_i \) can only wear their own shoes or any shoes belonging to a guest with a higher index number.

3. **Consider the worst-case scenario:**
   In the worst-case scenario, the first few guests take the largest available shoes, leaving the smaller shoes for the remaining guests. Let's analyze this step-by-step:

   - Suppose \( P_1 \) picks \( S_{10} \) (the largest pair of shoes).
   - \( P_2 \) picks \( S_9 \).
   - \( P_3 \) picks \( S_8 \).
   - \( P_4 \) picks \( S_7 \).
   - \( P_5 \) picks \( S_6 \).

   At this point, the remaining shoes are \( S_1, S_2, S_3, S_4, S_5 \).

4. **Analyze the remaining guests:**
   - \( P_6 \) cannot wear \( S_1, S_2, S_3, S_4, \) or \( S_5 \) because these shoes are too small for \( P_6 \).
   - Similarly, \( P_7, P_8, P_9, \) and \( P_{10} \) also cannot wear any of the remaining shoes.

5. **Conclusion:**
   Therefore, the largest number of guests who might have had to spend the night there is 5, as \( P_6, P_7, P_8, P_9, \) and \( P_{10} \) cannot find a pair of shoes big enough for their feet.

The final answer is \(\boxed{5}\).