public class Main {
public static void main(String[] args) {
boolean hasAccessCard = true;
boolean hasSecurityClearance = false;
boolean canEnterRestrictedArea = hasAccessCard || hasSecurityClearance;
System.out.println("Can the user enter the restricted area? " + canEnterRestrictedArea);
}
}
// Output: Can the user enter the restricted area? true
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter