MathTop

append 函数

将元素追加到列表末尾。

语法

  • append(list, item)

参数与选项

list形如 [1, 2, 3] 的列表字面量。
item要追加的元素。

示例

  1. 追加元素append([x, y], z)返回 [x, y, z]。