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 json | |
import pyzytemp | |
def main(): | |
t = None | |
co = None | |
x = pyzytemp.find() | |
if x: | |
temp = x[0] | |
attempts = 8 |
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
input :: [String] | |
input = [ | |
"billowy", | |
"biopsy", | |
"chinos", | |
"defaced", | |
"chintz", | |
"sponged", | |
"bijoux", | |
"abhors", |
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
type Point = (Double,Double) | |
type Triangle = (Point,Point,Point) | |
type Sierpinski = [Triangle] | |
midpoint :: Point -> Point -> Point | |
-- ^point between two points | |
midpoint (x1,y1) (x2,y2) = ((x1 + x2) / 2, (y1 + y2) / 2) | |
vec :: Point -> Point -> Point | |
-- ^two points into a vector |
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
#!/bin/bash | |
editors="ed ex vi emacs" | |
echo $editors | sed s/\ /\\n/g | shuf | head -1 |
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
#!/usr/bin/python3 | |
from collections import deque | |
from time import sleep | |
from os import system | |
def tilt(): | |
with open('/sys/devices/platform/lis3lv02d/position') as f: | |
return int(f.read().split(",")[1]) |
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
#!/usr/bin/env python3 | |
import glob | |
from PIL import Image | |
from random import shuffle | |
from sys import argv | |
# The maximum size an individual image can be | |
MAXSIZE = (640,480) |
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
#!/usr/bin/env python | |
""" | |
Trigram tool that takes text input and creates a random output based | |
on the N-grams of the input. | |
""" | |
import argparse | |
from sys import stdin | |
from random import choice |
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
#!/bin/bash | |
# subtree merge with branches | |
rm -rf commcare-hq core-hq | |
git clone git://github.com/dimagi/commcare-hq.git | |
git clone git://github.com/dimagi/core-hq.git | |
cd core-hq |
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
class NCR { | |
// Take the factorial of an integer | |
public static int factorial(int num) | |
{ | |
int fact = 1; | |
for (int i = 1; i <= num; i++) | |
fact = fact*i; | |
return fact; | |
} |
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 <limits.h> | |
#include <stdio.h> | |
#define DEPTH (7) | |
long int max(long int a,long int b){return(a>b?a:b);} | |
long int min(long int a,long int b){return(a<b?a:b);} | |
short player(); | |
short ai(); |
NewerOlder