Skip to content

Instantly share code, notes, and snippets.

View shomah4a's full-sized avatar

shoma shomah4a

  • 20:05 (UTC +09:00)
View GitHub Profile
@shomah4a
shomah4a / except.py
Created September 1, 2012 08:42
こんな WithException みたいなのありそうだけどないのだろうか
#-*- coding:utf-8 -*-
class ExceptionNotRaised(Exception):
pass
class WithException(object):
def __init__(self, *exceptions):
@shomah4a
shomah4a / gist:3909728
Created October 18, 2012 03:34
括弧の対応チェック。折角頑張ったので
(lambda START='({[', END=')}]': __import__('sys').stdout.write(str(not bool(reduce((lambda stack, p:((lambda stack, p: stack+[p]) if p in START else (lambda stack, p: (lambda stack, p: stack[:-1]) if p == END[START.index(stack[-1])] else (lambda stack, p: stack+['a']))(stack, p))(stack, p)), '(()()()', [])))+'\n'))()
@shomah4a
shomah4a / sorteq.cpp
Created December 12, 2012 00:01
二つの文字列が片方の文字列を入れ替えた文字列であるかどうかの判定をする。 コンパイル時計算してみた版
#include <iostream>
template <char... values>
class Char;
template <char head, char... left>
class Char<head, left...>
{
public:
@shomah4a
shomah4a / sorteq.py
Created December 12, 2012 00:32
同じの Python で書くとこんなもんなのよね。
#-*- coding:utf-8 -*-
u'''
(ほぼ)同じロジック Python 版
'''
def delete_same(c, s):
u'''
文字列 s から文字 c を一つ取り除く
やるだけならこのほうが楽
@shomah4a
shomah4a / template.cpp
Created December 13, 2012 03:01
なんかいろいろげんかいをかんじる
#include <iostream>
#include <utility>
template <typename T, T... array>
class List;
template <typename T, T car, T... cdr>
class List<T, car, cdr...>
@shomah4a
shomah4a / gltest.py
Last active December 11, 2015 14:58
greenlet 継承もできるのかー
#-*- coding:utf-8 -*-
import uuid
import pickle
import greenlet
def print_uuid():
c = greenlet.getcurrent()
@shomah4a
shomah4a / diff.py
Last active December 12, 2015 03:09
assertEquals のエラーから diff をとる
#-*- coding:utf-8 -*-
import sys
import re
def main(args=sys.argv[1:]):
pass

ついに顕在化しはじめた「壁リスク」

英語圏ではかなり前から壁を登り続けることのリスクについて語られていたが、いよいよ具体的な弊害が出て来ているようなので、かいつまんでメモ。日本でもそう遠くない未来だと思う。

ボルダリングジムの不足

スラックラインのように需要が逼迫しているのに人材の供給が増えず需給ミスマッチが起っているわけではなく、需要も供給も減るという状況下でわずかだが需要が上回っているとう性質の悪い状況がボルダリングに起きている。特に深刻なのは安価なボルダリングジムの発見が絶望的に難しいという現実だ。

探し物はなんですか
掴みやすい石ですか
かぶりの中も スラブ中も 探したけれど見つからないのに
まだまだ探す気ですか
それより僕と登りませんか
壁の中へ 壁の中へ
行ってみたいと思いませんか
Woo woo woo
Woo woo woo
Woo woo woo さあ
#!/bin/sh
rm -rf .git
hg init .
hg add
hg commit -m 'git to hg'