Standard escape codes are prefixed with Escape:
- Ctrl-Key:
^[ - Octal:
\033 - Unicode:
\u001b - Hexadecimal:
\x1B - Decimal:
27
| var list = [1,1,1] //changing these values to [3,0,2] will output the perrin sequence | |
| var amount = 7 //changing this value will change the amount of numbers outputed. | |
| for(var i = 0; i < amount-3; i++) { //chaning the number that is subtracted from 'amount' is the original length of list | |
| var j = list[i]; | |
| var e = list[i+1]; | |
| list.push(j+e) | |
| } | |
| console.log(list) //change to 'document.body.innerHTML = list' to show on webpage or append to a div or paragraph if needed |
| var flip = function (dataArray) { | |
| var a = dataArray; | |
| for(var i = 0; i < a.length; i++) { | |
| var b = Math.random(0,1); | |
| var c = Math.round(b); | |
| if(c === 0) { | |
| a[i] = true; | |
| } | |
| if(c === 1) { | |
| var b1 = Math.random(0,1); |
Thanks everyone for commenting/contributing! I made this in college for a class and I no longer really use the technology. I encourage you all to help each other, but I probably won't be answering questions anymore.
This article is also on my blog, too.
Note: $ denotes the start of a command. Don't actually type this.
x86_64.sh. If I had a 32-bit computer, I'd select the x86.sh version. If you accidentally try to install the wrong one, you'll get a warning in the terminal. I chose `AnaTHIS GIST WAS MOVED TO TERMSTANDARD/COLORS REPOSITORY.
PLEASE ASK YOUR QUESTIONS OR ADD ANY SUGGESTIONS AS A REPOSITORY ISSUES OR PULL REQUESTS INSTEAD!
| var Complex = function(real, imag) { | |
| if (!(this instanceof Complex)) { | |
| return new Complex (real, imag); | |
| } | |
| if (typeof real === "string" && imag == null) { | |
| return Complex.parse (real); | |
| } | |
| this.real = Number(real) || 0; |