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
# | |
# CONSTANTS | |
# | |
PLAYER_ICON = 'X' | |
BOARD_SIZE = 3 | |
WELCOME_MESSAGE = '' | |
WIN_MESSAGE = '' | |
INVALID_MOVE_MESSAGE = '' |
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
def campaign_month(t1, t2): | |
if t1 > t2: | |
return campaign_month(t2, t1) | |
month_dict = {} | |
if t2.month == t1.month and t2.year == t1.year: | |
month_dict[t2.month] = t2.day - t1.day + 1 | |
else: | |
month_dict[t2.month] = t2.day | |
month_dict[t1.month] = monthrange(t1.year, t1.month)[1] - t1.day + 1 | |
if t2.month - t1.month > 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
''' | |
R Programming Programming Assignment 1 in Python 3.4 using only Standard Libraries | |
Example Usage: | |
pollutantmean('/Users/jackgolding/documents/specdata', 'sulfate', range(1,11)) | |
4.064 | |
''' |
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
from apscheduler.jobstores.base import JobLookupError | |
from apscheduler.schedulers.background import BackgroundScheduler | |
import time | |
def hello(): | |
print(time.localtime().tm_sec) | |
def kill_hello(scheduler): |
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
@! |
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
@! |