2007-12-01ãã1ã¶æéã®è¨äºä¸è¦§
ï¼ï¼é²ã®è¡¨ç¤ºãhdã«è¿ã¥ããã - è¨ç®æ©ã¨æ¯ããæ¥ã ã®ãã®å¾od -tx1 ã§ããã $ od -tx1 sendmail.rb | head -5 0000000 23 21 2f 75 73 72 2f 62 69 6e 2f 72 75 62 79 0a 0000020 72 65 71 75 69 72 65 20 27 6e 65 74 2f 73 6d 74 0000040 70 27 0a 0a 4â¦
cygwinå ã®rubyã ã¨pipeãã¤ãããªãã®ã§å¤é¨ããã°ã©ã å¼åºã§éãã >> url='http://www.google.co.jp/intl/ja/images/google_sm.gif' => "http://www.google.co.jp/intl/ja/images/google_sm.gif" >> puts [`wget -q -O - #{url} | convert -quality 30 -râ¦
$ wget -q -O - http://www.google.co.jp/intl/ja/images/google_sm.gif | convert -quality 30 -resize 200x200 - jpeg:- > a.jpgããã§è¯ããããã«ãã¤ãã«åãã¦MIMEã¨ã³ã³ã¼ãã§ããã $ wget -q -O - http://www.google.co.jp/intl/ja/images/google_sâ¦
以ä¸ã®ããã«ããã export http_proxy=http://[user[:password]@]host[:port]/wget w3mã§åç §ãã HTTP_PROXYã ã¨rubyã®open-uriãé§ç®ãªã®ã§å°æåã§çµ±ä¸ãã
ï¼çªç®ã®ã·ã¼ãã§éã¹ãã å·¦å³ã§ãããã ãã Public Declare Function SetTimer Lib "USER32" (ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long Public Declare Function KillTimer Lib "USER32"â¦
äºæç®ã®ã¯ã¼ã¯ã·ã¼ããã¹ã¯ãã¼ã«ããã Public Declare Function SetTimer Lib "USER32" (ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long Public Declare Function KillTimer Lib "USER32" (ByVâ¦
äºæç®ã®ã¯ã¼ã¯ã·ã¼ããã¹ã¯ãã¼ã«ããã Public Declare Function SetTimer Lib "USER32" (ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse As Long, ByVal lpTimerFunc As Long) As Long Public Declare Function KillTimer Lib "USER32" (ByVâ¦
å ç¨ã®ã¿ã¤ãã¼ãå¿ç¨ãã¤ã¤ããã¼ãã¼ãä¸ã§æ¼ããã¦ãããã¼ã決ã¾ã£ãã»ã«ã«è¡¨ç¤ºããããã©ã¼ã«ã¹ãç¡ãã¦ãåå¿ããã¨ããããããããã Public Declare Function SetTimer Lib "USER32" (ByVal hwnd As Long, ByVal nIDEvent As Long, ByVal uElapse Aâ¦
ãã¼ã«ã16x12ã®ä¸ããã¦ã³ãããããã°ã©ã ã initãå®è¡ããå¾ timerStartStopãå®è¡ããã¨åãããæ¢ã¾ã£ããããã ä¹ ãã¶ãã«ã¿ã¤ã使ã£ã¦æ¥½ããã£ãã Public Declare Function SetTimer Lib "USER32" (ByVal hwnd As Long, ByVal nIDEvent As Long, Bâ¦
rubyã§ãããã¨ã - è¨ç®æ©ã¨æ¯ããæ¥ã ã§ã¯è²ã¤ãæåãç»åãæ·»ä»ããéãæ¹ãã¢ãããã¦ããªãã£ããã¨ã«ä»æ¥æ°ãã¤ããããªãã®ããã®åå¿é²ã ãããï¼ç¬ã¨ãããã¨ã§ãããã #!/usr/bin/ruby require 'net/smtp' Net::SMTP.start( 'smtpServerAddress'â¦
$ echo -e '#include <stdio.h>\nint main(){FILE *f;f=fopen("./a.txt","w");fprintf(f,"hello,world");}'> a.c;gcc a.c ; ./a.exe $ cat a.txt $ echo -e '#include <stdio.h>\nint main(){FILE *f;f=fopen("./*","w");fprintf(f,"hello,world");}'> a.c;gcc a.c ; ./a.exe S</stdio.h></stdio.h>â¦
(define (is-prefix xs ys) (if (null? xs) #t (if (null? ys) #f (if (eq? (car xs) (car ys)) (is-prefix (cdr xs) (cdr ys)) #f)))) (define (match xs ys) (if (null? ys) #f (if (is-prefix xs ys) #t (match xs (cdr ys))))) (print (match '(3 5) '(1â¦
./doc/ã«æ¤ç´¢å¯¾è±¡ææ¸ãæ ¼ç´ã $ cp /usr/lib/estraier/estseek.cgi . $ cp /usr/share/hyperestraier/locale/ja/estseek.* . $ echo 'replace: ^file://home/èªåã®ãã¼ã /public_html{{!}}http://ãµã¼ãå/' >>estseek.conf $ estcmd gather -il ja -sd caâ¦
ã¾ãããã¼ãã¦ãããããããã ãã©ããªãã¨ãªãã ã¤ãã§ã«ãã¡ã¤ã«å ã®ã¡ã¿ã¿ã°ãå¤æ´ãã¦ãã $ for i in *.html ; do nkf -wd $i|sed s/euc-jp/UTF-8/ > ../doc/$i ; done
emacsã§ã¯ã¦ã¤ã³ãã¦ã¯å¥ã®æå³ãªã®ã§ãã¬ã¼ã ã¨ãããããã (setq frame-title-format "Emacs")ããã§å¤æ´ã§ããã
å æ¥ã® emacsã®haskellã¢ã¼ãã§C-cC-lã§èªåçã«mainãè©ä¾¡ããæ´ã«ã«ã¼ã½ã«ãç·¨éãããã¡ã«ã¨ã©ã¾ããã - è¨ç®æ©ã¨æ¯ããæ¥ã ã¯haskell-mode-2.3ã§ãã£ãã¿ããã ã ã©ããææ°ã¯2.4ã«ãªã£ã¦ãã http://www.iro.umontreal.ca/~monnier/elisp/#haskell-mâ¦
æ¬ç©ã¯ããã¦ã¿ã
æ£ç¢ºã«ã¯é åãããªã㦠nPmã®n=mã®ã¨ãã ãã import List main=print $ permutation [1..3] permutation (a:[]) = [[a]] permutation a = concat $ zipWith (\x y->map (x:) (permutation (delete x y))) a $ repeat açµæ *Main> main [[1,2,3],[1,3,2],[â¦
import List main=print a a=qsort [3,2,1,4,1,2] qsort [] = [] --qsort (x:xs) = qsort [y|y<-xs,y<x] ++ [x] ++ qsort [y|y<-xs,y>=x] qsort (x:xs) = qsort l ++ [x] ++ qsort r where (l,r)=partition (< x) xsçµæ *Main> main [1,1,2,2,3,4] *Main> emacså ¥ãã¦è¯ãã£ãã</x]>
nçªç®ã®è¦ç´ ã¨ãã以å¤ã®ãªã¹ããããªãã¿ãã«ãçæããã Prelude> let (l,a:r)=splitAt 1 [1..4] in (a,l++r) (2,[1,3,4]) Prelude> let (l,a:r)=splitAt 2 [1..4] in (a,l++r) (3,[1,2,4]) Prelude> let (l,a:r)=splitAt 3 [1..4] in (a,l++r) (4,[1,2,3â¦