Consider the above situation in which a magnet is moved towards a conducting circular loop. The north pole of the magnet faces the loop. As the magnet comes closer to the loop, the magnetic field increases; hence, flux through the loop increases. According to Lenz's law, the direction of induced current is such that it opposes the magnetic field that has induced it. Thus, the induced current produces a magnetic field in the direction opposite to the original field; hence, the loop repels the magnet.On the other hand, when the magnet is going away from the loop, the magnetic field decreases. Hence, flux through the loop decreases. According to Lenz's law, the induced current produces a magnetic field in the opposite direction of the original field; hence, the loop attracts the magnet.