Skip to content

Instantly share code, notes, and snippets.

View TurpIF's full-sized avatar
👋

Pierre Turpin TurpIF

👋
View GitHub Profile
@TurpIF
TurpIF / main.py
Created February 27, 2014 07:08
My CodINSA Solution (2013-2014)
def exo1():
ls = set([raw_input() for _ in xrange(int(raw_input()))])
print '\n'.join(['oui' if raw_input() in ls else 'non' for _ in xrange(int(raw_input()))])
#exo1()
def exo2():
def dist(x1, y1, x2, y2):
return abs(x1 - x2) + abs(y1 - y2)
pos_o, pos_f = None, None
@TurpIF
TurpIF / router.service
Created September 26, 2013 12:08
Custom service file to start a network interface to route ro another
# Custom service file to start a network interface to route to an other
#
# Use systemd from ArchLinux
# To install :
# Place this file in /etc/systemd/system with a chmod of 644 and root:root as
# owner. A configuration file is also required at /etc/conf.d/router.conf
# which contains some variable declarations.
#
# To start :
# # systemctl start router.service