A and B plays the following game: they choose randomly $k$ integers from $\{1,2,\dots,100\}$; if their sum is even, A wins, else B wins. For what values of $k$ does A and B have the same chance of winning?
1. **Define the problem and the function:**
   We need to determine for which values of \( k \) the probability of the sum of \( k \) randomly chosen integers from \(\{1, 2, \ldots, 100\}\) being even is equal to the probability of it being odd. Consider the generating function:
   \[
   f(x, y) = (1 + xy)(1 + x^2y)(1 + x^3y) \cdots (1 + x^{100}y)
   \]
   The coefficient of \( x^m y^k \) in \( f \) represents the number of \( k \)-element subsets with sum \( m \).

2. **Set \( x = -1 \):**
   By setting \( x = -1 \), we transform the function to:
   \[
   f(-1, y) = (1 - y)(1 - y^2)(1 - y^3) \cdots (1 - y^{100})
   \]
   The coefficient of \( y^k \) in \( f(-1, y) \) is the difference between the number of \( k \)-element subsets with even sums and those with odd sums.

3. **Simplify the function:**
   Notice that:
   \[
   f(-1, y) = (1 - y^2)^{50}
   \]
   This is because each pair \((1 - y^i)(1 - y^{101-i})\) simplifies to \((1 - y^2)\).

4. **Apply the binomial theorem:**
   Using the binomial theorem, we expand:
   \[
   (1 - y^2)^{50} = \sum_{j=0}^{50} \binom{50}{j} (-1)^j y^{2j}
   \]
   The coefficient of \( y^k \) is zero if \( k \) is odd because there are no odd powers of \( y \) in the expansion.

5. **Conclusion for odd \( k \):**
   Therefore, the coefficient of \( y^k \) is zero if and only if \( k \) is odd. This means that for odd \( k \), the number of \( k \)-element subsets with even sums equals the number of \( k \)-element subsets with odd sums.

6. **Alternative method using subset pairing:**
   Consider pairing each subset \( A \) with \(\{101 - x \mid x \in A\}\). If \( k \) is odd, each subset \( A \) and its pair have sums of opposite parity, ensuring an equal number of even and odd sums.

7. **Handling even \( k \):**
   For even \( k \), consider the unmatched elements in a subset \( A \). If there are \( m \) unmatched elements, we can form \( 2^m \) subsets by replacing each unmatched element \( x \in A \) with \( 101 - x \). If \( m > 0 \), the parities of the subset sums are split evenly. If \( m = 0 \), \( A \) must consist of \( k/2 \) pairs of elements summing to 101. The sum of such subsets is always odd if \( k \equiv 2 \pmod{4} \) and always even if \( k \equiv 0 \pmod{4} \), leading to an imbalance in the number of even and odd sums.

The final answer is \( \boxed{ k } \) is an odd number with \( 1 \leq k \leq 99 \).