Notice: This page requires JavaScript to function properly.
Please enable JavaScript in your browser settings or update your browser.
Learn Challenge: Debugging and Improving a Hydration Reminder Code | Mastering Python if-else Statements
Conditional Statements in Python

Swipe to show menu

book
Challenge: Debugging and Improving a Hydration Reminder Code

Task

Swipe to start coding

Your task is to debug and improve the code using if-else statements to provide the correct feedback for the user.

  • Use an else statement when water_intake is less than daily_goal.
  • Ensure that the else statement does not include a condition, as it automatically covers all remaining cases.

Solution

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

SectionΒ 2. ChapterΒ 3
We're sorry to hear that something went wrong. What happened?

Ask AI

expand
ChatGPT

Ask anything or try one of the suggested questions to begin our chat

book
Challenge: Debugging and Improving a Hydration Reminder Code

Task

Swipe to start coding

Your task is to debug and improve the code using if-else statements to provide the correct feedback for the user.

  • Use an else statement when water_intake is less than daily_goal.
  • Ensure that the else statement does not include a condition, as it automatically covers all remaining cases.

Solution

Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
Everything was clear?

How can we improve it?

Thanks for your feedback!

SectionΒ 2. ChapterΒ 3
Switch to desktopSwitch to desktop for real-world practiceContinue from where you are using one of the options below
We're sorry to hear that something went wrong. What happened?
some-alt