Skip to content

Instantly share code, notes, and snippets.

//Commonly streaming list
var streamers = ["ESL_SC2", "OgamingSC2", "cretetion", "freecodecamp", "storbeck", "habathcx", "RobotCaleb", "noobs2ninjas"];
//Now to begin with the coding
//This function tests to see if a stream is active
//This is where the bug is, I think...
var pullJSON;
function viewAllStreams() {
for (i = 0; i < streamers.length; i++) {
title:hl:/Dig | Home
layout:default
---
<h2 align="center">
<a href="https://github.com/andy5995/hldig">hl://Dig</a> is a fork of <a href="https://sourceforge.net/projects/htdig/">ht://Dig</a>, a world-wide-web search system for an intranet or small internet.
</h2>
<p>
hl://Dig Copyright &copy; 2017<br>
Please see the file <a href="https://github.com/andy5995/hldig/blob/master/COPYING">COPYING</a> for
license information.
processing infiles/all.sct
processing infiles/attrs.sct
processing infiles/cf_blocks.sct
processing infiles/cf_byname.sct
processing infiles/cf_byprog.sct
processing infiles/cf_general.sct
processing infiles/cf_types.sct
processing infiles/cf_variables.sct
processing infiles/config.sct
processing infiles/confindex.sct
function ajDiamond(input) {
input = input.toUpperCase();
var standardInput = ["A","B","C","D","E","F","G","H","I","J"];
var spacer = " ";
var index = standardInput.indexOf(input);
var halfArr = [];
var tempArr = [];
var sessionArr = function(index) {
var arr = [];
for (var i = 0; i < index; i ++) {
function binaryAgent(str) {
var binArr = [];
str = str.split(" ");
for (var i = 0; i < str.length; i++) {
binArr.push(String.fromCharCode(parseInt(str[i], 2)));
}
str = binArr.join("");
console.log(str)
Basic array drill solutions
https://repl.it/@ElliottAlexande/Creating-arrays-drill
https://repl.it/@ElliottAlexande/Adding-array-items-drills
https://repl.it/@ElliottAlexande/Accessing-array-items-drill
https://repl.it/@ElliottAlexande/Array-length-and-access-drill
https://repl.it/@ElliottAlexande/Array-copying-I-drill
https://repl.it/@ElliottAlexande/Array-copying-II-drill
https://repl.it/@ElliottAlexande/Squares-with-map-drill
https://repl.it/@ElliottAlexande/Sort-drill
https://repl.it/@ElliottAlexande/Filter-drill
What is scope? Your explanation should include the idea of global vs. local scope.
Scope is the idea of where a variable is accessible. Global scope means that the variable resides outside of any function and as a result can be accessed by anything. Local scope would mean that the variable is accessible only inside it's original function.
Why are global variables avoided?
Global variables can cause issues because that variable can be referenced by any function in the program and may be altered accidentally, rendering it useless to its original purpose.
Explain JavaScript's strict mode
Strict mode raises a reference error when a variable is defined without let or const. It helps to keep the code collaboration friendly and bug free.
What are side effects, and what is a pure function?
https://repl.it/@ElliottAlexande/min-and-max-without-sort-drill
https://repl.it/@ElliottAlexande/average-drill
https://repl.it/@ElliottAlexande/fizzbuzz-drill-js
function getTokens(rawString) {
// NB: `.filter(Boolean)` removes any falsy items from an array
return rawString.toLowerCase().split(/[ ,!.";:-]+/).filter(Boolean).sort();
}
function mostFrequentWord(text) { // define the function. It accepts one argument, "text"
let words = getTokens(text); // set a variable, "words", to the filtered and sorted output of "getTokens". It is an array of all the words present in "text"
let wordFrequencies = {}; // create an object, "wordFrequencies", to keep track of word quantities
for (let i = 0; i <= words.length; i++) { // begin for loop