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 | |
# pam_notify.py | |
# Author : Jeeyoung Kim | |
# Python script to notify user on login | |
FROM_ADDRESS = 'admin@example.com' | |
TO_ADDRESS = 'you@example.com' | |
def pam_sm_open_session(pamh, flags, args): | |
try: | |
from email.mime.text import MIMEText |
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>Venn diagram of order 4</title> | |
</head> | |
<body> | |
<div>Venn Diagram Experiment</div> | |
<div>Use the controls on the bottom left.</div> | |
<div id='canvas'></div> | |
<script src='https://raw.github.com/DmitryBaranovskiy/raphael/master/raphael.js'></script> |
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
# Author : Jeeyoung Kim | |
# Convoluted way to check for balanced parenthesis. | |
L = lambda f: lambda x : f(x + 1) | |
R = lambda f: lambda x : not x or f(x - 1) | |
D = {'(':'L', ')':'R'} | |
while True: | |
print 'please input sequence of parenthesises, like ()()((, or ((())())' | |
input = raw_input() |
NewerOlder