Antonio and Bernardo play the following game. They are given two piles of chips, one with $m$ and the other with $n$ chips. Antonio starts, and thereafter they make in turn one of the following moves:
(i) take a chip from one pile;
(ii) take a chip from each of the piles;
(ii) remove a chip from one of the piles and put it onto the other.
Who cannot make any more moves, loses. Decide, as a function of $m$ and $n$ if one of the players has a winning strategy, and in the case of the affirmative answer describe that strategy.
To determine the winning strategy for Antonio and Bernardo, we need to analyze the game positions and their outcomes. We will use the concept of winning and losing positions in combinatorial game theory.

1. **Base Case Analysis:**
   - The position \((0,0)\) is a losing position because no moves are possible.
   - The positions \((1,0)\), \((0,1)\), and \((1,1)\) are winning positions because from each of these positions, the player can move to \((0,0)\), which is a losing position.

2. **Graph Representation and Moves:**
   - We represent the game positions as \((x, y)\), where \(x\) and \(y\) are the number of chips in the two piles.
   - The possible moves from \((x, y)\) are:
     - \((x-1, y-1)\) if \(x > 0\) and \(y > 0\)
     - \((x-1, y)\) if \(x > 0\)
     - \((x, y-1)\) if \(y > 0\)
     - \((x-1, y+1)\) if \(x > 0\)
     - \((x+1, y-1)\) if \(y > 0\)

3. **Inductive Step:**
   - A position \((x, y)\) is a losing position if all positions reachable from it are winning positions.
   - A position \((x, y)\) is a winning position if there is at least one losing position reachable from it.

4. **Pattern Identification:**
   - From the base cases and further analysis, we observe that:
     - \((2,0)\) and \((0,2)\) are losing positions because the only moves lead to winning positions.
     - \((3,0)\), \((3,1)\), \((2,1)\), \((1,2)\), \((1,3)\), and \((0,3)\) are winning positions because they can move to \((2,0)\) or \((0,2)\), which are losing positions.

5. **General Pattern:**
   - We notice that positions where both \(x\) and \(y\) are even (i.e., \((x, y)\) where \(x \equiv 0 \pmod{2}\) and \(y \equiv 0 \pmod{2}\)) are losing positions.
   - Positions where at least one of \(x\) or \(y\) is odd are winning positions.

6. **Conclusion:**
   - If the initial position \((m, n)\) is such that both \(m\) and \(n\) are even, then the first player (Antonio) is in a losing position.
   - If either \(m\) or \(n\) is odd, then the first player (Antonio) is in a winning position.

The final answer is: Antonio wins if \( \boxed{ m } \) or \(n\) is odd; otherwise, Bernardo wins if both \(m\) and \(n\) are even.