|
@@ -294,4 +294,17 @@ class Stack {
|
|
PushLength() {
|
|
PushLength() {
|
|
this.stack.push(this.stack.length);
|
|
this.stack.push(this.stack.length);
|
|
}
|
|
}
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+/**
|
|
|
|
+ * Get the char code of any character
|
|
|
|
+ *
|
|
|
|
+ * Can actually take any length of a value, but only returns the
|
|
|
|
+ * char code of the first character.
|
|
|
|
+ *
|
|
|
|
+ * @param {*} value Any character
|
|
|
|
+ * @returns {int} The value's char code
|
|
|
|
+ */
|
|
|
|
+function dec(value) {
|
|
|
|
+ return value.toString().charCodeAt(0);
|
|
}
|
|
}
|