Python Conditional And Statement In Matlab