mirror of
https://github.com/krahets/hello-algo.git
synced 2025-07-15 04:38:30 +08:00
Update the structure of the chapter
of binary tree.
This commit is contained in:
@ -63,13 +63,6 @@ class ArrayQueue {
|
||||
return nums[front];
|
||||
}
|
||||
|
||||
/* 访问索引 index 处元素 */
|
||||
int get(int index) {
|
||||
if (index >= size())
|
||||
throw new IndexOutOfBoundsException();
|
||||
return nums[(front + index) % capacity()];
|
||||
}
|
||||
|
||||
/* 返回数组 */
|
||||
public int[] toArray() {
|
||||
int size = size();
|
||||
|
Reference in New Issue
Block a user