Skip to content

Instantly share code, notes, and snippets.

View onitonitonito's full-sized avatar
🎯
Focusing

Kay SuParX the Cat Person onitonitonito

🎯
Focusing
View GitHub Profile
@onitonitonito
onitonitonito / xmas_tree_2016_blinking.py
Last active December 28, 2019 02:53
Some modification on package file
"""
# 3년전 이맘때 쯤, 블링킹 xmas 트리
"""
import os
import time
import random
# print(__doc__)
filler = '.'
@onitonitonito
onitonitonito / model_car.py
Created June 1, 2017 04:43
Python, Object Oriented Programming -- Drill #01. Speed Up Your Car!
FORM_INTRO='''\
=================================
\tVEHICLE INFORMATION
---------------------------------
1. MODEL : %s (%s)
2. MAX SPEED : %d km/h
3. ACCELARAT : +_ %d kmh
4. STATUS : %d kmh
---------------------------------\n\n\n'''
@onitonitonito
onitonitonito / css_cache_buster_original.py
Last active July 24, 2017 16:51
Solving CSS Cache Problems in FLASK web framework on Windows Platform
'''
flask.org suggests to use snipets of cache buster as below
http://flask.pocoo.org/snippets/40/
'''
@app.context_processor
def override_url_for():
return dict(url_for=dated_url_for)
def dated_url_for(endpoint, **values):
@onitonitonito
onitonitonito / 01_guess_why.py
Last active June 29, 2017 01:02
Guess why? - looks a bit weird result.. describe WHY?
# Two Different Results
# Compare #A-1 to #B-1
# Guess why? thinking about join() function.
# board = [[ str(n) for n in range(7,12) ]] #A
board = [ str(n) for n in range(7,12) ] #B
print (board)
for t in board:
@onitonitonito
onitonitonito / test.ipynb
Created November 7, 2017 11:42
test jupyter notebook viewer --- nbviewer.jupyter.org
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
@onitonitonito
onitonitonito / lott.css
Last active August 11, 2018 02:33
pick_6numbers_out_of_45
#NUMBERS {
margin-top: 5vh;
font-size: 3em;
color: #fff;
text-align: center;
}
b {
# coding: utf-8
# ## 청라, 송도지역 미세먼지 측정값 스크래핑
# > 1. 송도 = http://air.incheon.go.kr/airinch/real3.html?area_other_index=999992
# > 1. 청라 = http://air.incheon.go.kr/airinch/real3.html?area_other_index=999991
#
# * Todo: 계측 센서 갯수가 다르므로 필터링 방식이 달라져야 한다
# * 송도 = 6개 / 청라 = 4개
# In[1]:
@onitonitonito
onitonitonito / gist:17400f9eed020e033279d8c2fa90a13c
Last active July 24, 2020 11:51
drawing Xmas tree around this time of year
"""
# 이맘 때, 한번 쯤 만들어 보는 Xmas 트리 - 생활코딩
# http://bit.ly/2EXwk1r
"""
# https://www.facebook.com/photo.php?fbid=3199985326694503
# &set=gm.3602534863120357&type=3&theater&ifg=1
import os
import time
@onitonitonito
onitonitonito / result_CMD.txt
Last active July 24, 2020 14:36
To Show Coordination X,Y Numbering on the BOARD (Field)
# show [27x15] text grid board
0 . 1 . 2
123456789012345678901234567
1 ........................... 1
2 ........................... 2
3 ........................... 3
4 ........................... 4
5 ........................... 5
@onitonitonito
onitonitonito / _add_syspath_root.py
Last active July 25, 2020 02:07
Multiple Move of Turtle Using QtPy UI - Use pre inputed coordination data
# ------ root path 를 sys.path.insert 시키는 코드 ... 최소 4줄 필요------
import os, sys # 1
top = "k_mooc_reboot" # 2 = name of Top folder
root = "".join(os.path.dirname(__file__).partition(top)[:2])+"\\" # 3 = root_dir for top folder
sys.path.insert(0, root) # 4
# ---------------------------------------------------------------------