Skip to content

Instantly share code, notes, and snippets.

Avatar

Gergely Gombos gombosg

View GitHub Profile
@gombosg
gombosg / stress_test.py
Created Mar 27, 2019
Stress testing for Coursera's Algorithmic Toolbox course
View stress_test.py
# file should export:
# functions = [f1, f2, ..., fn] functions to stress test (maybe the first will be the naive implementation)
# gen_params() - returns a list or tuple of function parameters to test the functions with
# in main file use if __name__=="__main__" for standard IO code so that you can submit it for grading
import sys
from time import time
import FILE as runner # import your filename here
@gombosg
gombosg / getBlockLists.sh
Last active Nov 27, 2020 — forked from johntyree/getBlockLists.sh
Make one large blocklist from the bluetack lists on iblocklist.com
View getBlockLists.sh
#!/usr/bin/env sh
# Link good as of May 2020
# Download lists, unpack and filter, write to stdout
curl -s -A 'Mozilla/5.0 (X11; Linux x86_64; rv:77.0) Gecko/20100101 Firefox/77.0' https://www.iblocklist.com/lists.php \
| sed -n "s/.*value='\(http:.*\?list=.*\)'.*/\1/p" \
| xargs wget -O - \
| gunzip \
| egrep -v '^#'
@gombosg
gombosg / elevatorSaga.js
Created May 16, 2018
My take on Elevator saga, completes until challenges 1-12 so far.
View elevatorSaga.js
{
init: function(elevators, floors) {
// ----------------------------
// INIT
// ----------------------------
let myFloors = [];
initFloors();