This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const content = `beetle: | |
arms/legs: #738334 | |
antennae: #4a5224 | |
back primary: #04ab44 | |
back highlights: #7adb8b | |
eyes: #2f2f2f | |
octopus: | |
primary: #ff615e | |
tentacle highlight: #ffa8a8 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
refinement of articles | |
run 1 | |
summarize paragraph by paragraph | |
bulletpoint evidence | |
run 2 | |
summarize overall ideas | |
bulletpoint concepts |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fetch("https://apply.vandyhacks.org/api/leaderboard") | |
.then(v => v.json()) | |
.then(v => { | |
x = v; | |
console.log("TEAM CODES:\n\n" + Array.from(new Set(v.map(v => [v.team?.name, v.team?.joinCode].join(": ")))).filter(v => v !== ": ").join("\n")); | |
console.log("EMAILS:\n\n" + Array.from(new Set(v.map(v => v.email))).filter(v => v).join("\n")) | |
}) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Album Rating | |
[10/10/2023] Wallsocket - underscores | |
<7>, the album uses a lot of off beats in an interesting way. | |
I liked the instrumentals in Geez Louise (and the drop!?!?!?). | |
My favorite song was "Locals (Girls like us) [with gabby start]" | |
"Seventyseven dog years" was also pretty good. | |
Instrumentals in "Uncanny long arms" was good | |
[10/11/2023] Transatlanticism (10th Anniversary Edition) - Death Cab for Cutie |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function PK(m, v) { | |
const round = n => Math.round(n*1000)/1000; | |
console.log(`P: ${round(m*v)} K: ${round(0.5*m*(v**2))}`); | |
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
class Node { | |
// properties | |
private Node left; | |
private Node right; | |
private int value; | |
// getters | |
public Node getLeft() { return left; } | |
public Node getRight() { return right; } | |
public int getValue() { return value; } | |
// setters |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.lang.StringIndexOutOfBoundsException; | |
import java.util.Scanner; | |
public class Palindrome { | |
// Part 1 | |
// O(n) | |
public static boolean palindromeIterative(String input) { | |
// filter text so it only contains lowercase letters and numbers | |
input = input.toLowerCase().replaceAll("[^a-z0-9]", ""); | |
// pairs the first half to the second half, so we only |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
function magic(a) { | |
let N = a.length; | |
let mean = a.reduce((a,b)=>a+b,0) / N; | |
let sd = 0; | |
for (let i=0; i<a.length; i++) { | |
sd += ((a[i] - mean) ** 2); | |
} | |
sd /= N - 1; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const fs = require('fs'), | |
request = require('request'); | |
const download = (uri, filename, callback) => { | |
request.head(uri, (err, res, body) => { | |
request(uri).pipe(fs.createWriteStream(filename)).on('close', callback); | |
}); | |
}; | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const testFolder = './'; | |
const fs = require('fs'); | |
let n = 0; | |
fs.readdir(testFolder, (err, files) => { | |
files.forEach(file => { | |
if (file.includes("(1)") || file.includes("(2)") || file.includes("(3)")) { | |
//console.log(file); | |
n++; |