/* Logical Operators / ÐогиÑеÑкие опеÑаÑоÑÑ "||" - опеÑаÑÐ¾Ñ OR "&&" - опеÑаÑÐ¾Ñ AND "!" - опеÑаÑÐ¾Ñ NOT */ public class F020_LogicalOperators { public static void main(String[] args) { int temperature = 22; boolean isWarm = temperature > 20 && temperature < 30; System.out.println(isWarm); // изменим temperature на 12 temperature = 12; isWarm = temperature > 20 && temperature < 30; System.out.println(isWarm); boolean hasHighIncome = true; boolean hasGoodCredit = true; boolean hasCriminalRecord = false; boolean isEligible = ((hasHighIncome || hasGoodCredit) && !hasCriminalRecord); // "||" - ÑÑо опеÑаÑÐ¾Ñ OR // "&&" - опеÑаÑÐ¾Ñ AND System.out.println(isEligible); } }