Flow of Control Usually the order of statement execution through a method is linear: one after another flow of control: the order statements are executed.

Similar presentations

Presentation on theme: "Flow of Control Usually the order of statement execution through a method is linear: one after another flow of control: the order statements are executed."— Presentation transcript:

12
Logical Operators What if we wanted to test for multiple conditions? For example, what if we want to print the temperature if it’s below 80 degrees and greater than 50 degrees? We use logical operators: if (temp 50) System.out.println(temp); Created by Emily Hill & Jerry Alan Fails