Initial logic gates file with helper functions