Hi Ruby Lovers,

I have a tough task need your help. I try to persuade my boss to adopt
Ruby in our project. The project is actually a re-construction of very
very old current system. during these days, we've been reading and
documenting the old system. A chance of promoting Ruby arose. I just
wrote a small program which replaced a now malfunctioning C program. The
C program is about 300 lines long, however my ruby program is:

File.open("output.txt","w+") do |f|
    File.open("input.txt").each_line do |line|
        fld=line.match(/.{4}(.{3})(.{6})(.{3}).{17}(.{6})/)
        f.print fld[0],"-",fld[1],"-",fld[2],fld[3]
    end
end

Now the headache is, they are pretty much determined on Java. I need to
write a Java version of the above program, just to show them: 1. how
simple a ruby program comparing to Java; 2. My selling point is that
when use ruby to program, you can concentrate on business logic, no need
to care about language issues, like variable declaration, close file
handle etc.

Can any Java programmers help?

Thanks!
Shannon