Skip to content

Logic: AND, OR, NOT · ⁨逻辑:AND、OR 与 NOT⁩

English

A club that checks both ends of the age

  • A club takes members only from 11 to 16. One test cannot say both ends.
  • AND is TRUE only when both tests are TRUE: Age >= 11 AND Age <= 16.
  • NOT flips a Boolean. The tasks use it on a flag, not on a number.

中文

社团要核对年龄的两端

  • 社团只收 11 到 16 岁。一个判断说不了两端。
  • 只有两个判断都为 TRUE 时,AND 才为 TRUE:Age >= 11 AND Age <= 16。
  • NOT 把布尔值反过来。练习里把它用在一个标志上,而不是用在一个数字上。

AND 把两个判断接在一起:14 岁两边都通过,所以录取;10 岁第一个判断不通过

Handout

Log in or create account · ⁨登录或创建账户⁩

IGCSE, A-Level · ⁨IGCSE、A-Level⁩ & AP · ⁨与 AP⁩