implemented orGate and orGate2