Skip to content

Instantly share code, notes, and snippets.

View zempo's full-sized avatar

Solomon Zelenko zempo

View GitHub Profile
# Unix (Terminal)
open -a "Google Chrome" --args --disable-gpu-vsync --disable-frame-rate-limit
# Windows (Command prompt)
start chrome --args --disable-gpu-vsync --disable-frame-rate-limit
@bradtraversy
bradtraversy / mongodb_cheat_sheet.md
Last active November 21, 2025 13:58
MongoDB Cheat Sheet

MongoDB Cheat Sheet

Show All Databases

show dbs

Show Current Database

@zempo
zempo / __replit_main__
Created December 12, 2018 07:58
validate object keys drill created by zempo1 - https://repl.it/@zempo1/validate-object-keys-drill
// running the function with `objectA` and `expectedKeys`
// should return `true`
const objectA = {
id: 2,
name: 'Jane Doe',
age: 34,
city: 'Chicago',
};
// running the function with `objectB` and `expectedKeys`
@zempo
zempo / __replit_main__
Created December 12, 2018 07:40
find by id drill created by zempo1 - https://repl.it/@zempo1/find-by-id-drill
// you can pass in `scratchData` to test out `findByid`
// your function
const scratchData = [
{ id: 22, foo: 'bar' },
{ id: 28, foo: 'bizz' },
{ id: 19, foo: 'bazz' },
];
function findById(items, idNum) {
return items.find(item => item.id === idNum);
@zempo
zempo / __replit_main__
Created December 12, 2018 07:13
Make student reports drill created by zempo1 - https://repl.it/@zempo1/Make-student-reports-drill
function makeStudentsReport(data) {
let report = [];
for (i = 0; i < data.length; i++) {
let student = data[i];
report.push(`${student.name}: ${student.grade}`);
}
return report;
}
/* From here down, you are not expected to
@zempo
zempo / __replit_main__
Created December 12, 2018 06:41
Looping over collections of objects example created by zempo1 - https://repl.it/@zempo1/Looping-over-collections-of-objects-example
const users = [
{
name: 'Bernard',
age: 29,
birthMonth: 'April',
},
{
name: 'Bernice',
age: 14,
birthMonth: 'December',
@EliCDavis
EliCDavis / WebGLBitwiseFunctions.shader
Created May 24, 2016 16:11
In absence of bitwise operators in WebGL 1.0, I used these methods as substitute.
// CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / /
// Notice the for loops have a hardcoded values for how far they can go (32)
// This is a result of WEBGL not allowing while loops. Change the value to what you find appropriate!
// CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / / CAUTION / / /
//
// Hopefully this gives you the format for making your own operators such as XOR, NAND, etc.
//
// Adapted from this thread:
// https://scratch.mit.edu/discuss/topic/97026/
@mbejda
mbejda / Industries.csv
Last active September 3, 2025 02:51
Compiled list of industries.
Industry
Accounting
Airlines/Aviation
Alternative Dispute Resolution
Alternative Medicine
Animation
Apparel/Fashion
Architecture/Planning
Arts/Crafts
Automotive
@patriciogonzalezvivo
patriciogonzalezvivo / GLSL-Noise.md
Last active November 20, 2025 17:46
GLSL Noise Algorithms

Please consider using http://lygia.xyz instead of copy/pasting this functions. It expand suport for voronoi, voronoise, fbm, noise, worley, noise, derivatives and much more, through simple file dependencies. Take a look to https://github.com/patriciogonzalezvivo/lygia/tree/main/generative

Generic 1,2,3 Noise

float rand(float n){return fract(sin(n) * 43758.5453123);}

float noise(float p){
	float fl = floor(p);
  float fc = fract(p);
@greyaperez
greyaperez / Most_Useful_Shell.sh
Created December 10, 2013 15:42
Some of the most useful bash/shell functions and aliases.
alias editbash='vim ~/.bashrc'
alias updatebash='source ~/.bashrc'
alias ls='ls -alC --color=auto'
function search (){
egrep -roiI $1 . | sort | uniq
}
function whereis (){
find . -name "$1*";