boolean
boolean — 形容詞
1. describing a kind of logic, used heavily in computers and search engines, where
布林的
用真/假兩種值的邏輯系統
describing a kind of logic, used heavily in computers and search engines, where every value is either true or false (often written as 1 or 0) and where pieces of information are joined using AND, OR, or NOT.
In Python, the variable is_open holds a Boolean value, so it is either True or False.
在 Python 裡,變數 is_open 存放的是布林值,只會是 True 或 False。
common compound: Boolean value
Yumi used a Boolean search to find papers that mention 'climate' AND 'rice' but NOT 'wheat'.
Yumi 用布林搜尋去找同時提到「氣候」和「稻米」但不含「小麥」的論文。
common compound: Boolean search
The professor drew a small circuit on the board to show how Boolean operators control electric current.
教授在黑板上畫了一個小電路,示範布林運算子如何控制電流。
Ari's first homework in computer science was to write a Boolean expression for an alarm system.
Ari 在資訊課的第一份作業,是為一套警報系統寫出一條布林運算式。
Boolean logic sits at the heart of every digital device, from a smart watch to a supercomputer.
從智慧手錶到超級電腦,所有數位裝置的核心都建立在布林邏輯上。
- binary
broader; describes anything with two states, not necessarily logical (binary code, binary star)
- logical
much wider; about reasoning in general, not the specific true/false system
- two-valued
technical, mostly in mathematical logic textbooks
- fuzzy
in logic, the opposite system: values can be anywhere between 0 and 1, not strictly true or false
文法句型
Boolean + noun (logic, value, expression, operator, search, algebra)
用法筆記
Almost always used directly before a noun (Boolean value, expression, operator, search, algebra, logic). Capitalised in formal writing because it comes from a person's name (George Boole), but lower-case 'boolean' is now standard in programming code (e.g. 'boolean isReady;' in Java).