Skip to content

Instantly share code, notes, and snippets.

View loisaidasam's full-sized avatar
🙌
🙌

Loisaida Sam loisaidasam

🙌
🙌
View GitHub Profile
@loisaidasam
loisaidasam / writeup.md
Created March 21, 2017 20:33
Oh My Rockness: 17 Bands To See At SXSW 2017
@loisaidasam
loisaidasam / ideas.md
Created February 21, 2017 16:54
2017 NBA Allstar Stats Ideas
@loisaidasam
loisaidasam / generator_with_mutable_data.py
Last active February 15, 2017 22:39
TIL about mutable python generator data
"""
TIL data used/returned in python generators doesn't have any special mutability
properties - they're just like the rest of us!
"""
In [1]: def generator():
...: result = [1, 2, 3, 4]
...: while True:
...: print "before", result
...: yield result
@loisaidasam
loisaidasam / lunch
Created February 13, 2017 19:26
CLI lunch place chooser, chosen randomly from a foursquare list
#!/bin/bash
API_VERSION="20140401"
CLIENT_ID="YOUR CLIENT ID HERE"
CLIENT_SECRET="YOUR CLIENT SECRET HERE"
LIST_ID="YOUR LIST_ID HERE"
# or if you're in downtown Atlanta you could use mine, based on:
# https://foursquare.com/loisaidasam/list/hifi-lunch-eats--atl-edition
LIST_ID="5873b4bb0b56564a748ca1d5"
@loisaidasam
loisaidasam / tips_about_forms.md
Created February 6, 2017 18:49
Tips About Forms
  • an HTML form with 1 text input, and 0 submit inputs, will submit when u hit enter in the text input
  • an HTML form with > 1 text inputs and 0 submit inputs will NOT submit when u hit enter on any text input
  • an HTML form with any amount of text inputs, and 1 submit input, will submit when u hit enter on any input

TIL / FYI / TMYK

@loisaidasam
loisaidasam / README.md
Last active November 4, 2016 17:08
How to Javascript in 2016

Here I was, all this time, thinking that JQuery was how people still did things.

Apparently Javascript has changed since I last looked, and things are simpler/more baked in.

Here are the new things:

Getting Elements

Where JQuery let you do:

@loisaidasam
loisaidasam / 1_problem_description.txt
Last active November 4, 2016 19:33
Befunge Email Decode Problem
Advice for Contacting Barak
Want to hire me? Send me an email. I read most things.
*Really* want to hire me? Get the output of this Befunge program for a priority address. I guarantee a response.
(Befunge rules here: https://en.wikipedia.org/wiki/Befunge)
@loisaidasam
loisaidasam / README.md
Last active March 31, 2022 18:46
Scraped Mitch Hedberg jokes
@loisaidasam
loisaidasam / console.aws.amazon.com.js
Last active October 20, 2016 19:45
AWS Normalized instance hours cost using dot.js
/**
* Add actual cost in `Normalized instance hours` column
*
* Q: How do you calculate the Normalized Instance Hours displayed on the
* console ?
*
* On the AWS Management Console, every cluster has a Normalized Instance Hours
* column that displays the approximate number of compute hours the cluster has
* used. Normalized Instance Hours are hours of compute time based on the
@loisaidasam
loisaidasam / README.md
Created October 17, 2016 18:46
Your name in Japanese

Ever want to hear your name in Japanese? Now you can!

Steps (to download the mp3):

  1. Visit https://translate.google.com/#auto/ja and type in your name

  2. Click the audio icon to hear what your name sounds like in Japanese (yay!)

  3. [cmd] + [option] + j (in Chrome) to open the console, and click the Network tab.