This file contains hidden or 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
""" | |
# 3년전 이맘때 쯤, 블링킹 xmas 트리 | |
""" | |
import os | |
import time | |
import random | |
# print(__doc__) | |
filler = '.' |
This file contains hidden or 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
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''' |
This file contains hidden or 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
''' | |
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): |
This file contains hidden or 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
# 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: |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains hidden or 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
#NUMBERS { | |
margin-top: 5vh; | |
font-size: 3em; | |
color: #fff; | |
text-align: center; | |
} | |
b { |
This file contains hidden or 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
# 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]: |
This file contains hidden or 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
""" | |
# 이맘 때, 한번 쯤 만들어 보는 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 |
This file contains hidden or 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
# show [27x15] text grid board | |
0 . 1 . 2 | |
123456789012345678901234567 | |
1 ........................... 1 | |
2 ........................... 2 | |
3 ........................... 3 | |
4 ........................... 4 | |
5 ........................... 5 |
This file contains hidden or 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
# ------ 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 | |
# --------------------------------------------------------------------- | |
OlderNewer