Illustrated · 1 min
When the direction of the current of two wires is in the same direction, there is always an attractive force between the two wires. When the direction of the current of the two wires is in the opposite direction, there is a repulsive force between the two wires.
Example:

Find the magnetic force between wire I and II. Note: The figure is not drawn to scale for sake of clearness. Wire I is at the center of the circle and the circle passes through Wire II.
(distance around the circle)
is the force of Wire I on Wire II

In this example, the current of the two wires point in opposite directions so there is a repulsive force