Sovi.AI - AI Math Tutor

Scan to solve math questions

QUESTION IMAGE

2.1.5 plants main.py 1 needs_water = true 2 3 print( eeds water: \ + st…

Question

2.1.5 plants
main.py
1 needs_water = true
2
3 print(
eeds water: \ + str(needs_water))
write a program to help you take care of your plants!
a boolean variable called needs_water exists that represents whether or
not one of your plants needs water. it is set to true and its value is being
printed to the screen.
make another boolean variable called needs_to_be_repotted that
represents whether or not you need to repot one of your plants. set the
value to false and print it to the screen.
your output should look like this:
needs water: true
needs to be repotted: false

Explanation:

Step1: Declare the variable

needs_to_be_repotted = False

Step2: Print the variable

print("Needs to be repotted: " + str(needs_to_be_repotted))

Answer:

needs_water = True
needs_to_be_repotted = False
print("Needs water: " + str(needs_water))
print("Needs to be repotted: " + str(needs_to_be_repotted))