Quad nand circuit