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
#!usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" maimiku_search.py | |
マイミクの指定ユーザーの日記を全文検索する | |
""" | |
import os | |
import pickle | |
import sys | |
import mymixi_diary # http://d.hatena.ne.jp/ama-ch/20080725/1216995714 |
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
#!usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" fudemame.py | |
マイミクの日記更新頻度を調べる | |
""" | |
import datetime | |
import pickle | |
import mymixi_diary | |
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
#!usr/bin/env python | |
# -*- coding: utf-8 -*- | |
""" mymixi_diary.py | |
マイミク+自分の日記をダウンロードする | |
""" | |
import os | |
import pickle | |
import re | |
import time | |
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
#!/usr/bin/python | |
# -*- coding: utf-8 -*- | |
""" warikan.cgi | |
飲み会で使える割り勘電卓 | |
""" | |
import cgi | |
import cgitb; cgitb.enable() | |
print "Content-type: text/html" | |
html = """ |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
import datetime | |
d1 = datetime.date(2008, 4, 22) | |
d2 = datetime.date(2008, 5, 15) | |
print "みんなのPython学習期間は%d日間です。" % (d2 - d1).days |
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
#!/bin/sh | |
for i in $(grep -l hoge *); # "hoge"を含むファイル名の一覧を取得 | |
do | |
sed s/hoge/fuga/g $i > tmpfile # hogeをfugaに置換して一時ファイルへ吐く | |
mv tmpfile $i # 一時ファイルを元の名前にリネーム | |
done |
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
ul { | |
width: 320px; | |
} | |
li { | |
width: 100%; | |
padding: 15px 3px; | |
border-bottom: 1px dashed #ccc; | |
position: relative; | |
} |
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
.hoge { | |
border: 1px solid #666; | |
width: 100px; | |
height: 100px; | |
background-color: #ccc; | |
-webkit-transition: 0.3s ease-out; | |
transform: scaleY(1); | |
} | |
.hoge:hover { |
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
div { | |
border: 1px solid #ccc; | |
} | |
div:hover { | |
background-color: red; | |
} |
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
<!DOCTYPE html> | |
<html> | |
<head> | |
<meta charset="UTF-8"> | |
<title>CodePen · A Pen by ama-ch</title> | |
<link rel="stylesheet" href="http://codepen.io/stylesheets/css/normalize.css"> |
OlderNewer