Skip to content

Instantly share code, notes, and snippets.

:octocat:
Normal Stuff

EJ Mason EJMason

:octocat:
Normal Stuff
  • Pluralsight
  • Salt Lake City, UT
Block or report user

Report or block EJMason

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
@EJMason
EJMason / cloudSettings
Created Oct 24, 2019
Visual Studio Code Settings Sync Gist
View cloudSettings
{"lastUpload":"2019-10-24T16:45:58.315Z","extensionVersion":"v3.4.3"}
@EJMason
EJMason / main.js
Created Oct 9, 2019
Nestjs/jwt buffer error
View main.js
const jwt = require('jsonwebtoken')
const secret_string = 'Thisissupersecretstuff'
const secret_b64 = Buffer.from(secret_string, 'base64')
const str_b64 = secret_b64.toString('base64')
var token = jwt.sign({ foo: 'bar' }, secret_b64)
@EJMason
EJMason / lowGlossPetg
Created Nov 10, 2018
Prusa i3 MK3 3DXTech Low gloss PETG ini
View lowGlossPetg
# generated by Slic3r Prusa Edition 1.41.0+ on 2018-11-09 at 17:21:35
avoid_crossing_perimeters = 0
bed_shape = 0x0,250x0,250x210,0x210
bed_temperature = 85
before_layer_gcode = ;BEFORE_LAYER_CHANGE\n;[layer_z]\n\n
between_objects_gcode =
bottom_solid_layers = 4
bridge_acceleration = 1500
bridge_angle = 0
bridge_fan_speed = 100
View plinko.cpp
#include <iostream>
#include <iomanip>
#include <cmath>
#include <string>
using namespace std;
View insertionSort.js
const insertionSort = arr => {
for(let i = 0; i < arr.length; i++) {
// set the value to be inserted to a temp value
let temp = arr[i]
// find where the element is to be inserted
for(var j = i - 1; j >= 0 && arr[j] > temp; j--) {
// shift elements right until the correct location is found
arr[j + 1] = arr[j]
}
// insert element into the proper location
View bubble.js
const bubbleSort = arr => {
for (var i = 0; i < arr.length; i++) {
for (var j = 0; j < (arr.length - i - 1); j++) {
if(arr[j] > arr[j + 1]) {
//Swap the numbers
var tmp = arr[j]
arr[j] = arr[j + 1]
@EJMason
EJMason / SeperateChainingHash.js
Created Mar 30, 2017
Seperate Chaning implementation using Javascript
View SeperateChainingHash.js
// ---------- Separate Chaining (Open Hashing) ----------- //
const bucketHashTable = function(max) {
let _size = max || 23
let _hash = Array(_size).fill(null)
this.insert = function(value) {
let key = bucketHash(value)
View selectionSort.js
const selectionSort = list => {
for(let trail = 0; trail < arr.length; trail++) {
for(let i = trail; i < arr.length; i++) {
if(arr[i] < arr[trail]) {
let temp = arr[i]
arr[i] = arr[trail]
@EJMason
EJMason / main.js
Created Mar 14, 2017
This is a test gist
View main.js
app.get('/', (req, res) => {
res.status(200).send('Hello World!');
});
You can’t perform that action at this time.