I hereby claim:
- I am afrase on github.
- I am aaronfrase (https://keybase.io/aaronfrase) on keybase.
- I have a public key whose fingerprint is 4EE0 AFCF 0CFE 0281 BAD7 4E10 252A C9D9 2330 E13C
To claim this, I am signing this object:
# This class converts a point and a given radius into a polygonal circle. | |
# The error_distance is a parameter to the number of sides the polygon will have. | |
# The lower the number, the more sides it will have, and the more accurate the circle. | |
class CircleProcessor | |
TO_RADIANS = Math::PI / 180.0 | |
MIN_NUM_SIDES = 4 | |
MAX_NUM_SIDES = 1000 | |
TO_METERS = 6_371_008.7714 # Earth's mean radius in meters. | |
def initialize(error_distance) |
{ | |
"basics": { | |
"name": "Aaron Frase", | |
"label": "Senior Software Engineer at RVshare", | |
"image": "https://avatars.githubusercontent.com/u/3135411?v=4", | |
"email": "afrase91@gmail.com", | |
"phone": "", | |
"summary": "Self-taught programmer with a passion for writing clean, readable, and efficient code. Always looking to learn new things and better myself whether it's learning a new design pattern, programming language, or just the latest framework. Driven to wear many programming hats with expertise in creating everything from new applications to programming languages.", | |
"profiles": [ | |
{ |
RAD_PER_DEG = 0.017453293 | |
Rmiles = 3956 | |
def haversine_distance(lat1, lon1, lat2, lon2) | |
dlon = lon2 - lon1 | |
dlat = lat2 - lat1 | |
dlon_rad = dlon * RAD_PER_DEG | |
dlat_rad = dlat * RAD_PER_DEG |
I hereby claim:
To claim this, I am signing this object:
L1 cache reference ......................... 0.5 ns
Branch mispredict ............................ 5 ns
L2 cache reference ........................... 7 ns
Mutex lock/unlock ........................... 25 ns
Main memory reference ...................... 100 ns
Compress 1K bytes with Zippy ............. 3,000 ns = 3 µs
Send 2K bytes over 1 Gbps network ....... 20,000 ns = 20 µs
SSD random read ........................ 150,000 ns = 150 µs
Read 1 MB sequentially from memory ..... 250,000 ns = 250 µs
# -*- coding: utf-8 -*- | |
import threading | |
from collections import deque | |
from functools import wraps | |
from select import select | |
from socket import socket, AF_INET, SOCK_STREAM | |
from urllib.request import urlopen | |
class TaskException(Exception): |
#!/bin/bash | |
FORTUNES_BIN=$(which fortune) | |
COWSAY_BIN=$(which cowsay) | |
# on ubuntu you have to have `force_color_prompt=yes' set if you want to see | |
# all the pretty colors. | |
LOLCAT_BIN=$(which lolcat) | |
if [ -z "$FORTUNES_BIN" ] || [ -z "$COWSAY_BIN" ]; then | |
# just exit normally so we don't screw with the motd |
/** | |
* Check whether the name in the certificate matches the host | |
* we're talking to. | |
*/ | |
private static void checkCert(X509Certificate cert, String host) | |
throws IOException | |
{ | |
String name; | |
try | |
{ |