Conditionals 3 - logical operators


pseudocode | java


Classwork

In a text document:

For each of the following statements, think about input, including variable names and types; prompt the user for input; then, using a single if statement with logical operators, make the decision. In your if you can just print a statement about what happened.

  1. Teens between 12 and 18 who have had a flu shot can attend the presentation.
  2. Our apartment complex allows up to 2 cats or 1 dog as long as the dog is under 25 pounds
  3. Run the dishwasher if it has more than 25 items, or has at least one item and hasn't been run for three days