Question 1
Write a function is_positive_odd_or_negative_even that checks if an integer is either a positive odd number or a negative even number. Return True if the number meets one of these conditions; otherwise, return False.
NOTE: This is a function type question, you don't have to take input or print the output, just have to complete the required function definition.
Example cases
0-->False(neither positive nor negative)3-->True(positive odd)-4-->True(negative even)4-->False(positive but even)-3-->False(negative but odd)
Your task
Implement this function:
def is_positive_odd_or_negative_even(n: int) -> bool:
Write the function only — the arguments are read for you and the return value is printed automatically.
Arguments arrive as one Python literal per line, in this order: n.
Example
Input
0
Output
False