@@ -549,12 +549,15 @@ class CodeBox {
* The stack class
*/
class Stack {
- constructor() {
+ /**
+ * @param {int[]} stackValues An array of values to initialize the stack with
+ */
+ constructor(stackValues = []) {
/**
* The stack
* @type {int[]}
- this.stack = [];
+ this.stack = stackValues;
* A single value saved off the stack
* @type {int}