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
from pymongo import MongoClient | |
from time import time | |
import redis | |
import sys | |
SIZE = int(sys.argv[1]) | |
MONGODB_READ_RESULTS = 0 | |
MONGODB_WRITE_RESULTS = 0 | |
REDIS_READ_RESULTS = 0 | |
REDIS_WRITE_RESULTS = 0 |
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
private static boolean test(Object exp, Object actual, String test) { | |
String output = null; | |
if (exp.equals(actual)) { | |
output = "✔ Passed " + test; | |
System.out.println(output + "\n"); | |
return true; | |
} | |
output = "***** FAILED ***** " + test + "\n" + | |
"Expected: " + exp + ", Actual: " + actual; | |
System.out.println(output + "\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
public class SetTester { | |
/** | |
* Runs tests on primitive data types | |
* pre: exp != null, actual != null, test != null | |
* post: output test failure or success | |
*/ | |
private static boolean test(Object exp, Object actual, String test) { | |
String output = null; | |
if (exp.equals(actual)) { |
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.util.ArrayList; | |
public class BSTTester { | |
/** | |
* Runs tests on primitive data types | |
* pre: exp != null, actual != null, test != null | |
* post: output test failure or success | |
*/ | |
private static boolean test(Object exp, Object actual, String test) { |
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
TEST SUMMARY | |
Test name: C S 314 Assignment 11 (Huffman) scoring test | |
Results: Passed: 26, Failed: 0, No result: 0 | |
Classes tested: | |
* class SimpleHuffProcessor, loaded from file:/Users/shreydesai/Documents/workspace/Huffman/bin/ | |
Environment: Java version 1.8.0_91, maximum heap size 3641 MB, running on Mac OS X 10.11.6 (x86_64) |
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
public class GraphAndRankTester { | |
public static void main(String[] args) { | |
testGraph1(); | |
testGraph2(); | |
testFootballRanker(); | |
} | |
private static void testGraph1() { |
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
"""Mass personalized email script""" | |
import sys | |
import smtplib | |
import argparse | |
from email import encoders | |
from email.mime.text import MIMEText | |
from email.mime.base import MIMEBase | |
from email.mime.multipart import MIMEMultipart |
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
# Reload config | |
bind r source-file ~/.tmux.conf; display ' Reloaded' | |
# Colors | |
set -g default-terminal "screen-256color" | |
# Remaps leader | |
set-option -g prefix C-a | |
bind-key C-a last-window |
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
colorscheme dracula | |
" Only do this part when compiled with support for autocommands. | |
if has("autocmd") | |
" Use filetype detection and file-based automatic indenting. | |
filetype plugin indent on | |
" Use actual tab chars in Makefiles. | |
autocmd FileType make set tabstop=8 shiftwidth=8 softtabstop=0 noexpandtab | |
endif |
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
set background=dark | |
highlight clear | |
if exists("syntax_on") | |
syntax reset | |
endif | |
let g:colors_name = "dracula" | |
hi Cursor ctermfg=17 ctermbg=231 cterm=NONE guifg=#282a36 guibg=#f8f8f0 gui=NONE |
OlderNewer