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
#include <iostream> | |
#include <initializer_list> | |
#include <vector> | |
using namespace ::std; | |
template <typename E> | |
class NestedList { | |
public: | |
class Element { |
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
**/__pycache__ |
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
*.pyc | |
*~ |
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 __future__ import print_function | |
import csv | |
import os | |
import sys | |
import cv2 | |
def freak_out(msg): |
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 math | |
import operator | |
def normalize_azimuth_radians(angle): | |
positive = (angle % 2 * math.pi) | |
return positive if positive <= math.pi else positive - 2 * math.pi | |
class Vector(object): | |
def __init__(self, x, y): |
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
-module(running_total). | |
-export([new/2, update/2, update_silently/2]). | |
-export([sum/0, truncated_sum/1]). | |
new(Reducer, Initial) -> | |
spawn_link(fun() -> run(Reducer, Initial) end) | |
. |
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
-module(assassin). | |
-export([linked/2]). | |
% Monitors a gen_server2 for responsiveness by periodically sending | |
% is_healthy requests, and expecting a response in an amount of time | |
% specified by user of this module. | |
% | |
% Like supervisor, N out of M failures are allowed (where failure | |
% means response took too long). |
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
<!doctype html> | |
<html> | |
<head> | |
<title>Wat</title> | |
</head> | |
<body> | |
<script> | |
/* Support */ |
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
-module(id_server). | |
-behavior(gen_server). | |
-export([init/1, code_change/3, terminate/2]). | |
-export([handle_call/3, handle_cast/2, handle_info/2]). | |
% Unlike Snowflake (Twitter) or Flake (boundary), one of the goals here is for | |
% IDs to be scattered. This is because it is assumed that there will be some | |
% kind of sorted index on IDs. In that case, IDs that correlate with time would |
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
-module(click_server). | |
-behavior(gen_server). | |
% For gen_server behavior. | |
-export([ | |
% life cycle functions | |
init/1, code_change/3, terminate/2, | |
% handle_* service provider functions | |
handle_call/3, handle_cast/2, handle_info/2]). | |
% For users of this module. |
NewerOlder