Is Negative?
Beginner
Is Negative?
Let's imagine we're detectives trying to find negative numbers! Our job is to create a special function that will help us identify if a number is negative.
In this challenge, you'll write a function called is_negative. This function will take a single number as its input and return True if the number is negative, or False if it is zero or positive.
Here's how you can use the is_negative function:
is_negative(-3) # returns: True is_negative(0) # returns: False is_negative(2) # returns: False
Are you ready to become a number detective and find those negative numbers? Let's get started!
Inputs
Arg 1:
-3Expected Output
trueActual Output