Skip to content

Instantly share code, notes, and snippets.

Avatar
🍰
Eating cake

Jerome Martinez jromeem

🍰
Eating cake
View GitHub Profile
View gist:05ad61604518a89d0115c99fdca3242f
### Keybase proof
I hereby claim:
* I am jromeem on github.
* I am jromeem (https://keybase.io/jromeem) on keybase.
* I have a public key whose fingerprint is D5B0 C2C5 9145 2274 EE63 7387 B18E F40F 0E90 71A2
To claim this, I am signing this object:
View P5 401: Phyllotaxis
int numFlorets = 500;
float angleFloret = 137.5;
int scaleFloret = 15;
void setup() {
size(500,500);
}
void draw() {
background(255);
View P5 401: Finding the maximum in a list
int[] numbers = {1,2,3,6,1,6,48,38,77,23};
void setup() {
int x = findMaximum(numbers);
println(x);
}
int findMaximum(int[] someNumbers) {
int currentMax = someNumbers[0];
View victor.cpp
#define OFF_THE_CHARTS 10000000000000000000000000000000000000000bitch00000000000000000
Class Victor : Person
{
Private:
int mDramaticLevel;
int mCoolnessLevel;
int mNerdLevel;
Public:
View make_these_photos_into_a_gif.sh
#!/bin/sh
# Jerome Martinez
# MON20-APR15: gif making or whatev idk
# nyoom
WOOSH1="woosh1.gif"
WOOSH2="woosh2.gif"
OUTFILE="woosh.gif"
# lmao im gurl
@jromeem
jromeem / CFGProd.py
Created Feb 27, 2013
well formed brackets of many types! python is awesome! hooray for noam chomsky + regular grammars! :D
View CFGProd.py
# Jerome Martinez
# 19 February 2013
# Context-free grammar production
# This is our grammar:
#
# S -> SS [NonTerm, NonTerm]
# S -> ( S ) [LPAREN, NonTerm, RPAREN]
# S -> [ S ] [LBRACK, NonTerm, RBRACK]
# S -> { S } [LBRACE, NonTerm, RBRACE]
View es.sh
cd ~
sudo apt-get update
sudo apt-get install openjdk-7-jre -y
wget http://download.elasticsearch.org/elasticsearch/elasticsearch/elasticsearch-0.20.1.tar.gz -O elasticsearch.tar.gz
tar -xf elasticsearch.tar.gz
rm elasticsearch.tar.gz
sudo mv elasticsearch-* elasticsearch
sudo mv elasticsearch /usr/local/share
View CaveRuner.java
import java.io.IOException;
import java.util.ArrayList;
import java.util.Random;
import org.lwjgl.LWJGLException;
import org.lwjgl.input.Keyboard;
import org.lwjgl.input.Mouse;
import org.lwjgl.opengl.Display;
import org.lwjgl.opengl.DisplayMode;
import org.lwjgl.opengl.GL11;
@jromeem
jromeem / ngrams.py
Created Aug 22, 2012
In the fields of computational linguistics and probability, an n-gram is a contiguous sequence of n items from a given sequence of text or speech. --wiki
View ngrams.py
# Jerome Martinez
# N-Gram parser
# November, 10, 2011
# run through command line:
# arguments: <input_file_name> <output_file_name> <n-gram_count>
# (optional) arguments: <input_file_name> --verbose <n-gram_count>
# outputs the n-gram as a dictionary
# of keys and values where the key