The circuits that drive these motors are quite different. In the case of a bipolar motor two H-bridge circuits are used. Unipolar motors require a simple switching circuit for each phase, four being the most common.
Using an ohmmeter, the individual coils of a bipolar motor can easily be identified.
When dealing with unipolar motors the first task is to isolate the common wire. Using an ohmmeter, note the resistance between pairs of wires. As can be seen in the above diagram, the common wire will have half the resistance of the other wires across the coils.
Once the common wire has been found attach it to a supply voltage (5v to 12v in the case of printer motors)
As can be seen, the individual numbering of steps is not important as the order of the sequence. Reversing the order will reverse the direction of rotation.
The total number of steps required for one 360 degree rotation is determined by how the motor is constructed and will therefore may different for each motor.