Skip to content

Instantly share code, notes, and snippets.

View erichoco's full-sized avatar

erichoco

  • Meta
  • University of Illinois at Urbana-Champaign
View GitHub Profile
for i in range(10):
filename = 'table_{}.csv'.format(i) # or filename = 'table_%d.csv' % i
with open(filename, 'w') as file:
file.write('this is loop {}'.format(i))

Patisserie

  • Pierre Herme -- personal favorite, popular: deux-milles feuille, macarons, special-flavored (lichee or sth) croissant
  • Laduree -- famous for macaron
  • Sadaharu Aoki -- Japanese-styled French patisserie, I remember yuzi tart, matcha eclair are pretty good
  • Carl Marletti -- also famous

Eats

  • Au P'tit Grec -- famous small crepe and galette shop, neighborhood is also nice in the evening
  • Chez Papa 13 -- cheap French bristo, I remember the portion's big and with lots of chips
  • Song Heng Restaurant -- Vietnamese pho and vermicelli, if you like Vietnamese food you'll love it
@erichoco
erichoco / paris.md
Last active April 8, 2018 06:17
巴黎

觀光客必玩

  • 鐵塔 -- 從 Trocadéro 過去比較有 fu
  • 凱旋門
  • 羅浮宮 -- 進去可以逛超久,一天逛不完
  • 聖母院 -- 要不要上去見仁見智、可順便看看 Sainte Chapelle、市政廳(Hotel de Ville)
  • 凡爾賽宮(離市區火車大概 1 個多小時)有空可去看一下這浮誇的地方
  • 塞納河畔 -- 新橋、藝術橋一帶,可以往南逛左岸(Blvd Saint-Germain)

比上面不有名一點

  • 龐畢度
import os
import sys
import signal
import time
import csv
import re
from selenium import webdriver
from selenium.webdriver.common.by import By
from selenium.webdriver.support.ui import WebDriverWait
from selenium.webdriver.support import expected_conditions as EC
@erichoco
erichoco / w3_SensingTilt.pde
Created July 4, 2016 15:52
GaussSense for Processing Widget #3: creates WebSocket client for GaussSense Desktop
import websockets.*;
import processing.serial.*;
import gausstoys.core.*;
//Thresholds for sensing (Unit: Gauss)
final int W = 400;
final int H = 400;
final float LO_PRESENCE_THLD = 3;
final float HI_PRESENCE_THLD = 10;
final float TILT_THLD = 75;
# init a dict
d = dict()
d = {}
d = {'Name': 'Zara', 'Age': 7, 'Class': 'First'} # like js object
# get
d['Name'] # 'Zara'
d['Gender'] # KeyError # Don't use this
# dict.get(key, default=None)
@erichoco
erichoco / gausssense-header.js
Last active June 16, 2016 03:19
Debug headers inspired by Phaser to show the awesomeness of GaussSense 🍻
function headerA() {
var v = "0.0.1";
// check if the brower is Chrome or Safari w/o jQuery
if (/Chrome/.test(navigator.userAgent) && /Google Inc/.test(navigator.vendor) ||
/Safari/.test(navigator.userAgent) && /Apple Computer/.test(navigator.vendor)) {
var args = [
'%c %c %c GaussSense Desktop %c %c %c %c %c GaussSense.js v' + v + ' %c %c %c http://gausstoys.com 🍻',
'background: #f8afbc',
'background: #f4788f',
@erichoco
erichoco / README.md
Last active August 29, 2015 14:14
Explanation on Arduino part of GoMouve project

GoMouve

prototype version 0.1

This document provides a tutorial on how to set up GoMouve prototype, and explains the mechanism behind it.

Introduction

Set Up

Components

@erichoco
erichoco / 0_reuse_code.js
Last active August 29, 2015 14:11
Here are some things you can do with Gists in GistBox.
// Use Gists to store code you would like to remember later on
console.log(window); // log the "window" object to the console
@erichoco
erichoco / ConvertCoord.cpp
Last active August 29, 2015 14:04
Conversion of 3D coordinates in Vicon System to 2D coordinates. EyeWrist.
#include <stdlib.h>
#include <iostream>
#include <fstream>
#include <sstream>
#include <vector>
#include <deque>
#include <math.h>
using namespace std;