Let $G$ be a connected graph and let $X, Y$ be two disjoint subsets of its vertices, such that there are no edges between them. Given that $G/X$ has $m$ connected components and $G/Y$ has $n$ connected components, what is the minimal number of connected components of the graph $G/(X \cup Y)$?
1. **Understanding the Problem:**
   - We are given a connected graph \( G \).
   - \( X \) and \( Y \) are two disjoint subsets of vertices in \( G \) with no edges between them.
   - \( G/X \) denotes the graph obtained by contracting the subset \( X \) into a single vertex.
   - \( G/Y \) denotes the graph obtained by contracting the subset \( Y \) into a single vertex.
   - We are given that \( G/X \) has \( m \) connected components and \( G/Y \) has \( n \) connected components.
   - We need to find the minimal number of connected components of the graph \( G/(X \cup Y) \).

2. **Analyzing the Graph Contractions:**
   - Contracting \( X \) into a single vertex in \( G \) results in \( G/X \). Since \( G/X \) has \( m \) connected components, it implies that the contraction of \( X \) has split \( G \) into \( m \) parts.
   - Similarly, contracting \( Y \) into a single vertex in \( G \) results in \( G/Y \). Since \( G/Y \) has \( n \) connected components, it implies that the contraction of \( Y \) has split \( G \) into \( n \) parts.

3. **Considering the Contraction of \( X \cup Y \):**
   - When we contract \( X \cup Y \) into a single vertex, we need to consider how the connected components of \( G \) are affected.
   - Since \( X \) and \( Y \) are disjoint and there are no edges between them, contracting \( X \cup Y \) will not create new edges between the components formed by \( X \) and \( Y \).

4. **Combining the Information:**
   - The number of connected components in \( G/(X \cup Y) \) will be influenced by the number of components in \( G/X \) and \( G/Y \).
   - Since \( G/X \) has \( m \) components and \( G/Y \) has \( n \) components, the minimal number of connected components in \( G/(X \cup Y) \) will be the maximum of \( m \) and \( n \).

5. **Conclusion:**
   - The minimal number of connected components of the graph \( G/(X \cup Y) \) is \( \max(m, n) \).

The final answer is \( \boxed{\max(m, n)} \).