Skip to content

Instantly share code, notes, and snippets.

View mmisono's full-sized avatar
🌫️
I may be slow to respond.

Masanori Misono mmisono

🌫️
I may be slow to respond.
View GitHub Profile
#!/usr/bin/python
# Usage : python latest.py -n 5 -0 ~/foo | xargs -0 -J% cp % /tmp
import os.path
import getopt
import glob
import sys
def main():
#/usr/bin/python
import Skype4Py
import Growl
import os
import sqlite3
import shutil
import time
handle_names = []
#!/usr/bin/python
import Skype4Py
skype = Skype4Py.Skype()
skype.Attach()
for i in xrange(skype.RecentChats.Count):
print "%-40s\t\t%s" % (skype.RecentChats[i].Name,
skype.RecentChats[i].FriendlyName)
" A ref source for GNOME References
" Version: 0.0.1
" Author : mfumi <[email protected]>
" : thinca <[email protected]>
" License: Creative Commons Attribution 2.1 Japan License
" <http://creativecommons.org/licenses/by/2.1/jp/deed.en>
let s:save_cpo = &cpo
set cpo&vim
function timer(){
local title icon min sec t
min=0
sec=0
t=0
title="Timer"
icon=""
while getopts m:s:t:i: OPT
do
GA1DArrayAlleleGenome
GA1DArrayGenome
GA1DBinaryStringGenome
GA2DArrayAlleleGenome
GA2DArrayGenome
GA2DBinaryStringGenome
GA3DArrayAlleleGenome
GA3DArrayGenome
GA3DBinaryStringGenome
GAAllele
@mmisono
mmisono / .zshrc
Created September 20, 2010 07:05
function latest(){
local dir num
num=1
while getopts hn: OPT
do
case $OPT in
"n" ) num="$OPTARG"
shift 2 ;;
* ) echo "Usage: $0 [-n number] [dir]" 1>&2
return;;
@mmisono
mmisono / .vimrc
Created September 18, 2010 17:59
function! s:aojproblem(id,lang)
let base_url = "http://rose.u-aizu.ac.jp/onlinejudge/ProblemSet/description.jsp?id="
let url = '"' . base_url.printf("%04d",a:id) . "&lang=" . a:lang . '"'
let winnum = bufwinnr(bufnr('AOJ:Problem'))
if winnum != -1
if winnum != bufwinnr('%')
exe "normal \<c-w>".winnum."w"
endif
setl modifiable
max = 100
main = do fizzbuzz 1
fizzbuzz :: Int -> IO()
fizzbuzz n | n == max = putStrLn $ _fizzbuzz (n)
| otherwise = do putStrLn $ _fizzbuzz n
fizzbuzz (n+1)
where
_fizzbuzz :: Int -> String
_fizzbuzz x | x `mod` 15 == 0 = "FizzBuzz"
main = do putStr $ unlines $ map fizzbuzz [1..100]
fizzbuzz :: Int -> String
fizzbuzz x | x `mod` 15 == 0 = "FizzBuzz"
| x `mod` 5 == 0 = "Buzz"
| x `mod` 3 == 0 = "Fizz"
| otherwise = show x