Skip to content

Instantly share code, notes, and snippets.

apiVersion: extensions/v1beta1
kind: DaemonSet
metadata:
name: logging
spec:
template:
metadata:
labels:
app: logging-app
spec:
import math
import random
import sys
from fractions import gcd
def giveMePrimes():
primeList = list()
for num in range(1000,10001):
if all(num%i!=0 for i in range(2,int(math.sqrt(num))+1)):
@bechampion
bechampion / curve.py
Created June 27, 2017 07:14
a basic curve
import numpy as np
import pylab as pl
def f(x):
return x**3 -3*x + 4
Y, X = np.mgrid[-10:10:100j, -10:10:100j]
print "res"
ys = list()
xs = list()
import numpy as np
import pylab as pl
def f(x):
return x**3 -3*x + 4
Y, X = np.mgrid[-10:10:100j, -10:10:100j]
pl.contour(X, Y, Y**2 - f(X), levels=[0])
pl.show()
@bechampion
bechampion / ecaddition.py
Created June 29, 2017 10:53
addition EC
import numpy as np
import pylab as pl
Y, X = np.mgrid[-10:10:100j, -10:10:100j]
# Domain Parameters
a = 3
bb = 7
def f(x):
return x**3 -a*x + bb
#include <linux/kernel.h>
#include <linux/module.h>
#include <linux/netfilter.h>
#include <linux/netfilter_ipv4.h>
#include <linux/init.h>
#include <linux/netfilter_bridge.h>
#include <linux/ip.h>
#include <net/netfilter/nf_tables_ipv4.h>
#include <net/netfilter/nf_tables.h>
@bechampion
bechampion / Makefile
Created July 5, 2017 12:47
Make for foobar nf
obj-m += nf_foobar.o
all:
make -C /lib/modules/$(shell uname -r)/build M=$(PWD) modules
clean:
make -C /lib/modules/$(shell uname -r)/build M=$(PWD) clean
OPENSSH=/opt/openssh2
mkdir -p /opt/openssh2/dist/
cd ${OPENSSH}
wget http://zlib.net/zlib-1.2.11.tar.gz
tar xvfz zlib-1.2.11.tar.gz
cd zlib-1.2.11
./configure --prefix=${OPENSSH}/dist/ && make && make install
cd ${OPENSSH}
wget http://www.openssl.org/source/openssl-1.0.1e.tar.gz
URxvt.foreground: #ffffff
URxvt.background: #1d1f21
!! black
URxvt.color0: #282a2e
URxvt.color8: #373b41
!! red
URxvt.color1: #FF69B4
URxvt.color9: #cc6666
!! green
###############################################################################
# ceerious i3 status config
# see "man i3status" for documentation.
#
# It is important that this file is edited as UTF-8.
# The following line should contain a sharp s:
# ß
# If the above line is not correctly displayed, fix your editor first!
###############################################################################