MathTop

is_empty 函数

测试列表是否没有元素。

语法

  • is_empty(list)
  • IsEmpty(list)

参数与选项

list形如 [1, 2, 3] 的列表字面量。

示例

  1. 空列表is_empty([])返回 true。