Name | IntList整数型列表类 | ||||||||||||||||||||||||||||||||||||||
Examples | IntList inventory; void setup() { size(200, 200); inventory = new IntList(); inventory.append(84); inventory.append(15); inventory.append(102); println(inventory); noLoop(); fill(0); textAlign(CENTER); } void draw() { int nums = inventory.get(2); text(nums, width/2, height/2); }
|
||||||||||||||||||||||||||||||||||||||
Description | Helper class for a list of ints. Lists are designed to have some of the features of ArrayLists, but to maintain the simplicity and efficiency of working with arrays.
Functions like sort() and shuffle() always act on the list itself. To get a sorted copy, use list.copy().sort(). 整数列表的帮助器类。列表被设计为具有 ArrayLists 的一些功能, 但要保持使用数组的简单性和效率。 排序 () 和无序 () 之类的函数总是在列表本身上执行。若要获取已排序的副本, 请使用列表. 复制 (). 排序 ()。 |
||||||||||||||||||||||||||||||||||||||
Methods |
|
||||||||||||||||||||||||||||||||||||||
Constructor | IntList() IntList(items) |
||||||||||||||||||||||||||||||||||||||
Related | FloatList StringList |
- 本文固定链接: http://iprocessing.cn/2017/07/17/intlist整数型列表类/
- 转载请注明: 卡萨布兰卡 于 Processing编程艺术 发表