Are pins described here same as What exactly are 'pins'??
Pins are the physical pin that comes out of a device, for example it is the pins that you plug into a bread board. In the image below they are the tings that are numbered 1 to 14 for each device (7 pins on each side.) I also included a bit more info regarding pins at the bottom of this post.
Why does an inverter require two pins and power supply two pins?
An inverter has an input and a output (a total of 2 pins) and a power supply usually has a ground and positive (like +15vDc and Ground.)
Take a look at this pdf. If you click on a part it will show you the internal schematic (at least a simplified example,) this may help you understand whats going on.
Lets take the following NAND gate as an example:
It has a +6 volt input at the top, and ground at the bottom, so 2 pins for just the power, then it has the actual A and B input, and the output. So a total of 5 pins. You can get this in a 14 pin package, and it will actually have 4 NAND gates that you can use, as you can somewhat tell from this image:
These examples came from here, check it out for more information.
Suppose that there are three gates and two inverters. So if we have
14-pin package, is it possible to do this in the package?
3 gates = 9 pins
2 inverters = 4 pins
So with power and ground that would be a total of 15 pins, so technically no, however it completely depends on what is shared in the device. And there are a ton of different combinations available, you can see some of them in the pdf that I linked above.
Back to your question about Pins... You can see the pins in this 28 pin PDIP component. And the circle that is next to a pin on one end of the board (next to the label 'Half Moon',) is there to mark what pin is pin 1 (so you don't destroy the component by placing it into its socket backwards.)
Also, it is worth noting how the pins are numbered. It starts at 1 then goes down the row. When labeling the other side, the next pin is the pin that is directly across from the last pin on the other side (in this case, it is pin 15, and as you can see, it is directly across from pin 14.)
Here is an example of a surface mount IC. Notice the circle or hole is still marking pin 1. Of course you should always double check with the devices datasheet to make sure you have the correct device and can identify pin 1.
Hopefully this will help get you started. One more thing to note is that the label 'Half Moon' is not a term that is used (at least I don't believe I've heard it before.)