Skip to content

Instantly share code, notes, and snippets.

View masnnuller's full-sized avatar

Rikuo Takahama masnnuller

View GitHub Profile
*-zsh zone(3356)-*
/Users/mactkg/Desktop/pros% bash
*-bash zone(23750)-*
bash-3.2$ csh
*-csh zone(23756)-*
[athene:~/Desktop/pros] mactkg% ps -la
UID PID PPID F CPU PRI NI SZ RSS WCHAN S ADDR TTY TIME CMD
0 3352 62566 4106 0 31 0 2436324 1612 - Ss f1992a0 ttys000 0:00.25 login -pf mactk
501 3356 3352 4006 0 31 0 2437320 2724 - S cb37540 ttys000 0:00.18 -zsh
501 23750 3356 4006 0 31 0 2435548 996 - S 1cb527e0 ttys000 0:00.00 bash
@rosylilly
rosylilly / gist:3401612
Created August 20, 2012 06:40
先輩と覚える HTTP ステータスコード

先輩に学ぶ HTTP Status Code

超雑にまとめました。修正してください。

登場人物

  • アプリケーション先輩: いつも忙しい。横に広がるのが得意(デブじゃない)。
  • 後輩: 頼んでばっかしで役に立たない。
  • サーバー先輩: アプリケーション先輩と仲がいい。Unix Socket でつながるくらい仲良し。
  • プロクシ先輩: アプリケーション先輩とかサーバー先輩と後輩の間を取り持って代わりに伝えたりしてくれる。たまに勝手にレスポンスを書き換える。
@myuon
myuon / while.hs
Created January 7, 2014 14:03
whileを使ったループ(多分分かりやすくはない)
import Control.Monad
while :: (Monad m) => (a -> Bool) -> m a -> m a
while f m = do
a <- m
when (f a) $ while f m >> return ()
return $ a
main = do
putStrLn $ "Can you guess the number I have?"