38 bytes.
I took the idea from eban (http://jarp.does.notwork.org/diary/) 's 39B code :
which saves 3 bytes by changing $_.size into ~/$/.
However, since regexp ignores newline characters, we can remove -l option, thus saving one more byte.
http://jp.rubyist.net/magazine/?0023-RubiMaGolf
'Programming > Ruby' 카테고리의 다른 글
| [Anarchy Golf] Morse decode (2) | 2008/04/18 |
|---|---|
| Ruby로 짜본 간단한 369게임 (2) | 2008/04/08 |
| [Golf] るびまゴルフ 【第 3 回】38 bytes (0) | 2008/04/04 |
| [Golf] るびまゴルフ 【第 3 回】42 bytes (0) | 2008/03/31 |
| 루비 프로그램을 하나의 exe 파일로 바꾸기 (0) | 2008/03/31 |
| 테스트 주도 개발로 "숫자 세자리 마다 콤마 찍는 프로그램" 코딩하기 (2) | 2008/03/19 |



