Skip to content

Instantly share code, notes, and snippets.

View alanzchen's full-sized avatar

Alan Chen alanzchen

View GitHub Profile
#
# Worksheet A
#
# This worksheet is also a Python program. Your task is to read the
# task descriptions below and then write one or more Python statements to
# carry out the tasks. There's a Python "print" statement before each
# task that will display the expected output for that task; you can use
# this to ensure that your statements are correct.
#
from flask import Flask, request, jsonify
import json
from hashlib import sha256
from datetime import datetime
from glob import glob
import os
app = Flask(__name__)
SECRET = "some_random_string"
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alanzchen
alanzchen / Hangman-v3-Wordnik-final.ipynb
Created April 28, 2017 06:03
The hangman solution to Strikingly's hangman game.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alanzchen
alanzchen / Vocabulary_Audio_Generator.ipynb
Created April 5, 2017 04:45
This script takes the pronunciation and a short piece of human-friendly explanation from Vocabulary.com with which it generates a synthesised audio.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alanzchen
alanzchen / LDA_Profiling_Draft.ipynb
Created March 31, 2017 13:09
A draft of a jupyter notebook about profiling and matching authors and reviewers using LDA model for FindMyReviewers.com.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alanzchen
alanzchen / Google+Scholar-Simple-Parser.ipynb
Created February 23, 2017 08:37
A simple parser for Google Scholar profiles.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@alanzchen
alanzchen / keybase.md
Created January 16, 2017 04:57
keybase.md

Keybase proof

I hereby claim:

  • I am alanzchen on github.
  • I am alanchen (https://keybase.io/alanchen) on keybase.
  • I have a public key ASCTAEcX1pPYgMKi4hFzuLuFb-Hd5S0QIuYbiofxtipRnQo

To claim this, I am signing this object:

@alanzchen
alanzchen / WeChat_Pay_Bill_Export.py
Last active August 25, 2022 07:41
WeChat Pay Bill Export
# Install the Python Requests library:
# `pip install requests`
import requests
import datetime
import pickle
set_date = datetime.datetime
# Simply call get_record and it will return a json object containing your bill.
@alanzchen
alanzchen / Sendgrid to Telegram.js
Last active December 12, 2016 17:18
A scriptr.io script to bridge sendgrid notification and telegram.
//First, we'll require the 'http' library to use later for calling a 3rd party webservice
var http = require("http");
//Getting parameters from the request body. For a nested json, we only want the first one.
try {
var parameters = JSON.parse(request.rawBody);
parameters = parameters[0]
var ip = parameters.ip;
var email = parameters.email;