Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
We can make this file beautiful and searchable if this error is corrected: Illegal quoting in line 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
test,1 | |
test,2 | |
test,=1+2 | |
test,4 | |
test,=IMAGE("https://www.google.com/images/srpr/logo3w.png") |
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
十字の時計 2004-10-22 20:21:04 | |
柳沢呉服店 2004-06-07 01:53:19 | |
僕が居なくなる 2004-08-10 16:15:31 | |
リセットボタン 2004-10-15 01:27:52 | |
卒業旅行戦国記 ー珠緒の恋ー 2004-06-23 19:02:17 | |
みえるモノ・みえないモノ 2004-08-07 15:42:27 | |
総合調査会社アジディックファイル1ジャッジメント 2004-04-20 01:51:31 | |
キャリアウト〜Hold over operation 2004-05-21 22:29:13 | |
傲慢なる少年の傀儡 2004-05-02 01:40:21 | |
海の音 2004-07-19 08:02:24 |
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
import timeit | |
common_for = """ | |
for d in data: | |
s += d | |
""" | |
common_sum = """ | |
sum(data) | |
""" | |
common_numpy_sum = """ |
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 -*- | |
import math | |
def jaccard(v1, v2): | |
numerator = sum([c in v2 for c in v1]) | |
denominator = len(v1) + len(v2) - numerator | |
return float(numerator) / denominator if denominator != 0 else 0 | |
def dice(v1, v2): |
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
import sys | |
def count(MIN, MAX): | |
s = set() | |
L = len(str(MAX)) | |
for i in xrange(MIN, MAX + 1): | |
for j in xrange(1, L): | |
div = 10**j | |
h = i / div | |
l = i % div |
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
import sys | |
T = sys.stdin.readline() | |
i = 0 | |
for l in sys.stdin: | |
count = 0 | |
i += 1 | |
data = map(int, l.split()) | |
N, S, p = data[0:3] | |
G = data[3:] |
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
def fib_recursive(n): | |
if n == 1: | |
return 1 | |
if n == 2: | |
return 1 | |
return fib_recursive(n - 1) + fib_recursive(n - 2) | |
memo = {} | |
def fib_memo(n): | |
if n == 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
#!/usr/bin/env python | |
# encoding: utf-8 | |
import sys | |
import sqlite3 | |
from collections import namedtuple | |
conn = sqlite3.connect("wnjpn.db") | |
Word = namedtuple('Word', 'wordid lang lemma pron pos') |
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
#!/usr/bin/env python | |
# -*- coding: utf-8 -*- | |
u"""人生を24時間換算したときの今日の時間を表示 | |
This is released under the MIT License(http://www.opensource.org/licenses/mit-license.php). | |
Copyright (c) 2012 Satoru Ogasawara |