Created
January 15, 2025 19:20
-
-
Save lrlucena/b118e90a6025f95d4532f112c0c722d3 to your computer and use it in GitHub Desktop.
Implementação de funções lógicas em Python
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
def AND(a: bool, b: bool) -> bool: | |
if a: | |
return b | |
return False | |
def OR(a: bool, b: bool) -> bool: | |
if a: | |
return True | |
return b | |
def NAND(a: bool, b: bool) -> bool: | |
return '' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment