In the above example, we were dealing with input pins. Let us look at a simple digital circuit, the 74HC04 Inverter. The picture on the right shows the symbol for the 74HC04. Internally, this chip is constructed using transistors. I have taken great liberty by reducing the circuit to a single transistor version, T1.
Digital circuits use transistors as switches.
I have included a picture of a switch as well. These are functionally equivalent circuits. The actual implementation of the 74HC04 is much more complex, but the basic ideas presented are still valid. In digital circuits, output gates are switches. In the above drawing, you can see that the equivalent circuit using the switch demonstrates that the internals of an output gate use a pull-up resistor just like I described in the first article.