V2EX  ›  英汉词典
Enqueued related words: Predicate, Datatype

Bool

定义 Definition

bool:布尔类型;一种只表示两种逻辑值的基本数据类型,通常为 true/false(真/假)。常见于编程语言与逻辑表达式中。

发音 Pronunciation

/ˈbuːl/

例句 Examples

A bool can be either true or false.
bool 可以是真或假。

The function returns a bool indicating whether the user is authenticated, which helps the system decide what content to display.
该函数返回一个 bool,用来表示用户是否已通过认证,从而帮助系统决定显示哪些内容。

词源 Etymology

bool 通常被认为是 Boolean(布尔的)的缩写;而 Boolean 源自英国数学家 George Boole(乔治·布尔) 的姓氏,他的逻辑代数为现代计算机科学与数字电路奠定了基础。

相关词 Related Words

文学作品用例 Literary Works

bool 主要是编程术语,更多出现在技术书籍而非传统文学作品中;在计算机经典教材中常见,例如:

  • The C Programming Language(Kernighan & Ritchie)
  • The C++ Programming Language(Bjarne Stroustrup)
关于   ·   帮助文档   ·   自助推广系统   ·   博客   ·   API   ·   FAQ   ·   Solana   ·   4216 人在线   最高记录 6679   ·     Select Language
创意工作者们的社区
World is powered by solitude
VERSION: 3.9.8.5 · 19ms · UTC 08:47 · PVG 16:47 · LAX 00:47 · JFK 03:47
♥ Do have faith in what you're doing.