It is composed of a triode. When the input A is low potential, a positive potential is generated at the base through the result of R1 and R2 resistance voltage division, so that the triode is cut off, and then the negative potential is output at point B.
On the contrary, when the input end A is high potential, the voltage division result makes the base negative potential, so the transistor is on, and the B point outputs high potential. It has the function of logical not, which is called not gate.