I'm trying to use this if-else shorthand inside a function:
def isFull(): # checks wheteher stack is full
return True if top == (size - 1) else return False
But my IDE highlights the return
saying "Expected expression".
What is wrong with the code, and how do I fix it?